Get back online, activate, and install updates on your legacy Windows PC
Find a file
Adam Demasi 552c1bd418
Have reboot be done by the elevation helper
IE with low integrity doesn't seem to be able to get the shutdown privilege
(with good reason, I suppose). Do that from the elevated helper instead,
assuming one has been created. If not, just try doing it from the browser
anyway.
2024-12-12 00:27:29 +10:30
.github We aren't using nsis-pluginapi 2024-12-11 16:31:48 +10:30
.idea/.idea.LegacyUpdate/.idea Add Rider config junk 2024-09-29 03:31:06 +09:30
.vscode Add VSCode file associations 2024-09-30 16:57:20 +09:30
build Add script to patch Debian's NSIS with i486-capable binaries 2024-09-16 12:55:50 +09:30
include Use slc.dll for activation status on Vista+ 2024-09-30 16:57:18 +09:30
launcher I think we're meant to call CoInitializeEx() on launcher startup 2024-12-11 23:58:01 +10:30
LegacyUpdate Have reboot be done by the elevation helper 2024-12-12 00:27:29 +10:30
nsisplugin Fix the activation check on XP and Server 2003 x64 2024-11-10 22:29:02 -06:00
setup Avoid IE medium integrity elevation request prompt 2024-12-11 16:47:29 +10:30
shared Avoid IE medium integrity elevation request prompt 2024-12-11 16:47:29 +10:30
.editorconfig First 2022-10-07 01:54:41 +10:30
.gitattributes Tweak line endings config 2024-09-30 16:57:20 +09:30
.gitignore Add some output stuff to gitignore 2023-11-20 03:22:09 +10:30
.vsconfig Remove components from .vsconfig that are already included in the image 2024-10-17 12:35:14 -05:00
build.cmd Implement codesigning the dlls and setup 2023-10-05 00:07:30 +10:30
LegacyUpdate.sln Implement installing dual 32 and 64-bit binaries on amd64 2023-07-22 06:09:18 +09:30
LICENSE.md First 2022-10-07 01:54:41 +10:30
Makefile Another attempt to fix CI 2024-09-30 16:57:20 +09:30
README.md Update readme with more (current) info 2024-12-11 16:29:05 +10:30

Legacy Update

wakatime Build

Since Windows XP was discontinued in 2014, followed by Windows 7 in 2020, Microsoft has closed services they depend on, such as Windows Update. There are also design flaws with these earlier versions of Windows Update, which make them difficult to get working on new installations.

Legacy Update can install all relevant updates necessary to fix access to the Windows Update service on unsupported versions of Windows. These versions of Windows may display the error “Windows could not search for new updates: Windows Update encountered an unknown error” with error code 80072EFE, or may simply never finish checking for updates. Legacy Update identifies the updates your system lacks, and installs them automatically, restoring the Windows Update service to full functionality.

Windows Update provides many optional and recommended updates, in addition to drivers for your system, but Windows XP and 2000 can only install critical security updates through the built-in Automatic Updates feature. Legacy Update revives the original Windows Update website - the only way to see and install every update available for your system. Legacy Update also restores access to Windows Ultimate Extras on Windows Vista Ultimate.

Legacy Update also restores connectivity to some websites in Internet Explorer, and other programs that use the Windows built-in networking functionality. This includes Windows Product Activation on Windows XP and Windows Server 2003, allowing you to activate these versions of Windows online in seconds (a legitimate product key is still required).

Just want to appreciate the nostalgia of the classic Windows Update website? Legacy Update can also be installed on Windows 10 and 11. This works even on versions of these OSes that have removed Internet Explorer. Legacy Update wont modify your Windows 10 or 11 installation.

If this website helped you to update your old PCs, please consider leaving a tip to help me pay for the server costs. Thank you!

Download

Download the latest version from the Releases page of this repo, or from legacyupdate.net.

You can also download the latest nightly build, based on the current development work. Nightly builds are not guaranteed to be stable, and unlike release builds, require at least Windows 2000 SP4 or Windows XP SP2. You may also need to accept extra SmartScreen and other security warnings since these executables are unique to each build. If youre not sure what to download, you probably want the stable release.

The ActiveX Control

This repo hosts an ActiveX control used as a replica of the original one developed by Microsoft for the official Windows Update website. The original version of Legacy Update required using a proxy autoconfiguration file (.pac) and some additional configuration of Internet Explorer security settings to intercept requests to the update.microsoft.com domain, because the Microsoft Wuweb.dll control has safety measures ensuring it can only be used by the official update.microsoft.com domain. With the custom Legacy Update ActiveX control, proxying is no longer required, because we have full control over the validation logic.

This also allows us to extend it with convenient features not possible with JavaScript alone. Particularly, we have “forward-ported” the control to add support for Windows Vista and later, which introduces extra challenges such as User Account Control (UAC) and Internet Explorers Protected Mode.

Building

The project is built on Windows 10/11 with WSL 2. You can test much of the project using your running version of Windows, although for best results you should test using a virtual machine of Windows XP, Windows Vista, and Windows 7. Take snapshots of your VMs - this will make it far easier to test update scenarios.

You will need to install:

  • On Windows:
    • Visual Studio 2022 - select the following individual components:
      • Desktop development with C++
      • C++ Windows XP Support for VS 2017 (v141) tools
      • C++ ATL for v141 build tools (x86 & x64)
      • C++/CLI support for v141 build tools (14.16)
    • Visual Studio 2008 for compiling a build that works on XP RTM and 2000 SP4 - not required if you only want to build for XP SP2 and later
      • You will also need Visual Studio 2010, which provides bridging from 2008s VSBuild system to the modern MSBuild.
  • On Linux:

Run the following command to install Linux build dependencies. This command specific to Ubuntu - if you use a different distro, you will need to find and install the equivalent packages from your package manager.

sudo apt install make nsis upx-ucl mingw-w64-i686-dev mingw-w64-x86-64-dev

If you use Debian/Ubuntus build of NSIS, please note that it is compiled for Pentium II and later, and will fail to launch on Pentium, AMD K6, and other CPUs lacking SSE instructions. If you want to support these CPUs, run ./build/fix-nsis.sh to patch the NSIS exehead binaries with a build that supports these CPUs.

When opening the solution for the first time in Visual Studio 2022, it will suggest to retarget it against the latest Windows SDK. Cancel this dialog.

Testing

For debugging, if running on Windows XP with IE8, consider installing Utilu IE Collection. IE6/IE7 are more convenient for debugging the native code because of their simplistic single-process model. Visual Studio is able to launch it and directly attach to the process the code is running in. Otherwise, you will need to manually find and attach the debugger to the IE child process hosting the website and ActiveX control.

To configure the debugger:

  1. Right-click LegacyUpdate in the Solution Explorer → Properties
  2. In the Debugging tab, set the Command field to:
    • For system IE install: $(ProgramW6432)\Internet Explorer\iexplore.exe
    • For Utilu IE6 RTM: $(ProgramW6432)\Utilu IE Collection\IE600\iexplore.exe
    • For Utilu IE6 SP2: $(ProgramW6432)\Utilu IE Collection\IE600XPSP2\iexplore.exe
    • For Utilu IE7: $(ProgramW6432)\Utilu IE Collection\IE700\iexplore.exe
    • For PowerShell: $(SystemRoot)\System32\WindowsPowerShell\v1.0\powershell.exe (or SysWOW64 to test the 32-bit build on 64-bit Windows)
  3. If using IE, set the Command Arguments field to http://legacyupdate.net/windowsupdate/v6/, or any other URL you want to use for debugging
  4. In the Debugger tab, set Register Output to Yes. (If running on Windows Vista or later, start Visual Studio as administrator to ensure the rights needed for this.)

You can directly test the ActiveX control using PowerShell:

PS> $lu = New-Object -ComObject LegacyUpdate.Control
PS> $lu.CheckControl()
True

If set up correctly, CheckControl() should return True. This is only supported in debug builds - release builds throw E_ACCESSDENIED.

Setup and Launcher

Legacy Update makes use of the Nullsoft Scriptable Install System (NSIS) for its setup program. NSIS provides a scripting language we use to install prerequisite updates. We extend NSIS with a custom plugin to provide features that improve the setup user experience.

As of 1.10, Legacy Update includes a “launcher” program, responsible for tasks including launching the website in Internet Explorer, repairing a broken installation of Legacy Update, and continuing setup when the system restarts into Winlogon “setup mode”.

Both are compiled using MinGW-w64 and are written in C to keep things simple.

Website source code

I havent yet open sourced the website. This is because much of it is Microsoft code - just with patches Ive made to remove Microsoft trademark branding, switch it to the Legacy Update ActiveX control, and make some quality-of-life improvements. It doesnt feel appropriate to put an open source license on something I dont own. Since its almost entirely client-side HTML and JavaScript, you can still review it by poking around the source on the website. You might find DebugBar and CompanionJS (requires Visual Studio or standalone Microsoft Script Debugger) useful.

Ive tinkered with writing a ground-up replacement of the Microsoft-developed Windows Update website. I havent worked on this in a while, but Ill open source it when I feel its ready enough.

Disclaimer

The existence of this project shouldnt be taken as an endorsement to continue using unsupported OSes. You should stick to a supported OS such as Windows 10 or 11 (or, try Linux?!). However, this service exists anyway in recognition that using these OSes is sometimes necessary to run legacy hardware/software, or just interesting to play around with.

This project is not affiliated with or endorsed by Microsoft. This software is provided “as is”, without warranty of any kind. We dont believe anything should go wrong, but please ensure you have backups of any important data anyway.

Credits

Legacy Update was started and is primarily developed by Adam Demasi (@kirb), with contributions from:

We make use of some portions of the Windows SDK, MinGW-w64, and NSIS.

License

Licensed under the Apache License, version 2.0. Refer to LICENSE.md.

The repository includes some portions of NSIS, licensed under the zlib/libpng license. It also includes a compiled copy of my fork of NSxfer, licensed under the zlib/libpng license.