driver-updater

Windows app that checks Windows Update and hardware vendors for newer drivers and silently installs the driver.
git clone https://dittus.dev/git/driver-updater.git
Log | Files | Refs | README | Download

README.md | Raw


Driver Updater

Finds newer drivers for the hardware in a Windows PC and installs them. It checks Windows Update, then asks NVIDIA, AMD, and Intel directly. It updates only the drivers already in use and installs the driver alone, the way Device Manager's "Update driver" does. No vendor setup program runs and no vendor software gets installed.

Requirements

The app has no NuGet dependencies. WMI and Windows Update are COM objects called through dynamic.

Download

The installer is the Download link on https://dittus.dev/git/driver-updater/. It installs to C:\Program Files\Driver Updater and adds a Start Menu shortcut. Remove it from Settings, Apps.

The MSI isn't code signed, so Windows SmartScreen warns before it runs. Choose More info, then Run anyway.

Build and run

From the repo folder in an elevated terminal:

dotnet run

From a normal terminal, dotnet run fails with "The requested operation requires elevation". Build it and start the exe instead. Windows shows the UAC prompt.

dotnet build
start bin\Debug\net10.0-windows\DriverUpdater.exe

To build one exe that carries the .NET runtime (about 62 MB):

dotnet publish -c Release

It lands in bin\Release\net10.0-windows\win-x64\publish\DriverUpdater.exe.

From WSL, run the same commands with dotnet.exe so the Windows SDK does the build.

Build the installer

The installer wraps the published exe, so publish first:

dotnet publish -c Release
dotnet build installer -c Release

The MSI lands in installer\bin\Release\DriverUpdater.msi. It takes its version from the exe, so <Version> in DriverUpdater.csproj is the only place to change it. Never change the UpgradeCode in installer/Package.wxs. A newer MSI uses it to find and replace the installed copy.

Windows Installer can't write its database to the WSL share, so from WSL point the installer's build folders at a Windows path:

dotnet.exe build installer -c Release \
  '-p:BaseIntermediateOutputPath=C:\Temp\DriverUpdater-msi\obj\' \
  '-p:OutputPath=C:\Temp\DriverUpdater-msi\out\'

Without that, the build fails with WIX0223: Failed to open database.

Where updates come from

Source Devices Lookup Installs
Windows Update Anything Microsoft has a driver for Windows Update Agent API, searching Microsoft's servers for Type='Driver' Yes
NVIDIA GeForce GPUs getDispDrvrByDevid on gfwsl.geforce.com, keyed by PCI device ID Yes
AMD graphics Radeon GPUs and Ryzen integrated graphics drivers.amd.com/drivers/installer/json/version.json and the feeds it lists Yes
AMD chipset Devices already on an AMD chipset driver drivers.amd.com/drivers/installer/chipset/VersionInfo.xml, then the INFs in the package Yes, with 7-Zip
Intel Graphics, wireless, and Ethernet The Intel Driver & Support Assistant catalog at dsadata.intel.com/data/en No. Rows link to Intel's page

Each vendor endpoint is the one that vendor's own update tool calls. None of them is documented. Any of them can change without notice. AMD's server needs an amd.com Referer. Intel's needs a User-Agent. The app sends both.

Intel is check only because Intel packs graphics, Wi-Fi, and Bluetooth drivers in three different installer formats. Unpacking each needs its own code, and that needs Intel hardware to test on.

How it installs

Windows Update drivers download and install silently through the Windows Update Agent API.

Vendor drivers go through five steps:

  1. Download. The vendor's package goes to %TEMP%\DriverUpdater. A dropped download is retried twice.
  2. Signature. WinVerifyTrust checks the Authenticode signature, revocation included. The signer has to be NVIDIA Corporation or Advanced Micro Devices to match the source. If either check fails, the file is deleted.
  3. Unpack. NVIDIA's and AMD's graphics packages are 7z archives, which the tar.exe built into Windows reads. AMD's chipset package is an NSIS installer holding an InstallShield setup. 7-Zip opens the NSIS layer. The InstallShield layer unpacks itself through an MSI administrative install, which copies files out and installs nothing. AMD's own installer unpacks it the same way.
  4. Find the INF. The app looks for the INF that lists the device's most specific hardware ID, then its compatible IDs. IDs that only name a device class are skipped.
  5. Install. UpdateDriverForPlugAndPlayDevices installs that INF on the device with no UI and waits for it to finish. Windows replaces the driver only if it ranks the new one higher, so this never downgrades. The driver store checks the package's own signature.

Graphics packages unpack to 2 to 4 GB, so they're deleted after the install. The chipset package stays in %LOCALAPPDATA%\DriverUpdater, one folder per AMD release, because every scan reads it.

Before installing anything, the app creates a System Restore point. Clear the checkbox to skip it.

How versions are compared

Each vendor numbers drivers differently from Windows.

When something fails

What you see Cause Fix
Windows Update error 0x80240044 The app isn't running as admin Start it through UAC
Windows Update error 0x8024402C Windows Update can't reach Microsoft Check the network and proxy
Couldn't create a restore point System Protection is off for the system drive Turn it on in System Properties, or clear the checkbox
A row like NVIDIA check with Failed: ... The vendor changed or blocked its endpoint, or doesn't know the device The status shows the full error
The download isn't signed by ..., so it was deleted The download's signature is invalid or belongs to someone else Get the driver from the vendor's site
tar.exe failed or 7z.exe failed The vendor changed its package format The status shows the tool's error
Nothing in the package matches this device The package has no INF listing any of the device's IDs The vendor dropped the device, or the feed picked the wrong package
Windows kept the current driver Windows ranks the installed driver as good or better Nothing to do
Install 7-Zip to check these AMD chipset drivers need 7-Zip to unpack Install 7-Zip and scan again

Windows quietly skips a restore point if it made one in the last 24 hours. The app counts that as success.

Limits

Files

File What it does
MainWindow.xaml, MainWindow.xaml.cs The window, the scan, and the install loop
InstalledDevices.cs Reads devices, driver versions, and device IDs from WMI
WindowsUpdate.cs Searches, downloads, and installs through the Windows Update Agent API
Nvidia.cs, Amd.cs, Intel.cs One vendor check each
VendorPackage.cs Downloads, verifies, and unpacks a vendor package once for every row that needs it
Unpack.cs Runs tar.exe, 7-Zip, and other unpacking tools
DriverInf.cs Finds the INF for a device and ranks it against the installed driver
PnpDriver.cs Installs an INF through UpdateDriverForPlugAndPlayDevices
Authenticode.cs The signature check
RestorePoint.cs Creates the restore point through WMI
DriverUpdate.cs One row in the list
Com.cs, Web.cs COM object creation and the shared HttpClient
installer/ The WiX project that builds the MSI around the published exe