Execution
Installed Programs (Uninstall Keys, MSI, AppX)
Installed programs cheat sheet: Uninstall keys, MsiInstaller events 1033/11707, cached MSIs, AppX packages, winget logs and Amcache to date software installs.
- Location
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
- Proves
- Which software was installed or removed, where, roughly when and, for MSI installs, by which account
- Timestamps
- Uninstall key LastWrite (FILETIME, UTC), InstallDate string (YYYYMMDD, local date, no time), MsiInstaller event times (UTC), Amcache InstallDate
- Retention
- Uninstall keys persist until the product is uninstalled; Application.evtx rolls over at 20 MB by default, often weeks to months
- Access
- HKLM hives and Application.evtx are locked on a live system: raw copy or VSS as admin; live registry reads work as a standard user
- Evidence of
- ExecutionPersistence
- Type
- Registry
- Windows
- XPVista / 78 / 8.11011
- KAPE target
- RegistryHivesSystemRegistryHivesUserEventLogsAmcache
- Velociraptor
- Windows.Triage.Targets:RegistryHivesSystemRegistryHivesUserEventLogsAmcache
Tools
Compare all toolsWhat it is
Windows has no single package manager history, but several sources together play that role. The Uninstall registry keys feed "Apps & features" and "Programs and Features". Windows Installer (msiexec) logs every MSI install and removal to the Application log and caches the package under C:\Windows\Installer. Store and MSIX apps are tracked by the AppX deployment stack in a state database. Package managers such as winget and Chocolatey keep their own logs, and Amcache keeps an independent inventory. When an attacker installs a remote access tool, a VPN client or a vulnerable driver package, these are the places that record it.
Location
| Source | Path |
|---|---|
| Machine-wide, 64-bit | HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\<ProductCode or name> |
| Machine-wide, 32-bit on x64 | HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\... |
| Per-user installs | HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\... (in each user's NTUSER.DAT) |
| MSI product data | HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\<SID>\Products\<packed GUID>\InstallProperties |
| MSI events | C:\Windows\System32\winevt\Logs\Application.evtx, provider MsiInstaller |
| Cached packages | C:\Windows\Installer\*.msi and *.msp (hidden, random names) |
| AppX / MSIX | C:\Program Files\WindowsApps\, C:\ProgramData\Microsoft\Windows\AppRepository\StateRepository-Machine.srd, log Microsoft-Windows-AppXDeploymentServer/Operational |
| winget | Typically %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir\*.log |
| Chocolatey | Typically C:\ProgramData\chocolatey\logs\chocolatey.log and C:\ProgramData\chocolatey\lib\ |
| Amcache | C:\Windows\AppCompat\Programs\Amcache.hve, key Root\InventoryApplication (Windows 10+) |
Package manager paths depend on version and install scope; confirm on a reference system.
What it proves
- Presence of software: a product was registered as installed, with its name, version, publisher and install folder.
- Approximate install time: from
InstallDate, the key's LastWrite time and MsiInstaller events. - Who installed it: MSI events carry the user SID,
InstallPropertiessits under the installing SID (orS-1-5-18for per-machine), and HKCU entries belong to that profile. - Removal: event 1034 or 11724, and orphaned folders or cached MSIs after the Uninstall key is gone.
It does not prove the program was ever run. Portable tools (unzipped binaries, AnyDesk.exe run from Downloads) never create Uninstall keys; use Prefetch and Amcache file entries for those. An Uninstall key can also be written by hand, so treat a lone key as a claim, not proof.
Key fields
| Field | Meaning |
|---|---|
DisplayName, DisplayVersion, Publisher | What the product says it is |
InstallDate | YYYYMMDD string written by the installer; optional, date only |
InstallLocation | Install folder; pivot for $MFT and Amcache file entries |
InstallSource | Folder the installer ran from (Downloads, a share, a mounted ISO) |
UninstallString, QuietUninstallString | Command used to remove it; odd paths are suspicious |
WindowsInstaller = 1 | Product managed by MSI; key name is the ProductCode GUID |
LocalPackage (InstallProperties) | Path of the cached MSI in C:\Windows\Installer |
| MsiInstaller 1033 / 1034 | Product installed / removed, with name, version, manufacturer and status code |
| MsiInstaller 11707 / 11724 | Installation / removal completed successfully (11708 = install failed) |
Timestamps
- Key LastWrite (FILETIME, UTC): set at install, but also by repairs, updates and some self-updaters, so it is an upper bound on install time.
- InstallDate: local date with no time, written by the installer itself. Some installers leave it empty or write the build date.
- MsiInstaller events: precise UTC timestamps; the most reliable anchor for MSI products.
- Amcache
InventoryApplication: carries its ownInstallDateand aSourcefield (for exampleAddRemoveProgramorMsi); useful when the Uninstall key has been deleted. - Folder creation of
InstallLocationand of the cached.msi($SI and $FN in the $MFT) corroborate the install time.
Retention and clearing
Uninstall keys stay until the product is removed; a clean uninstall deletes the key but often leaves the install folder, Prefetch, Amcache entries and the MsiInstaller events behind. Application.evtx defaults to 20 MB and rolls over, so on busy servers MSI events may be gone within weeks. Deleted keys can survive in registry transaction logs, unallocated hive space and Volume Shadow Copies.
Collection
KAPE targets RegistryHivesSystem, RegistryHivesUser, EventLogs and Amcache cover most sources. On a live system:
# All three Uninstall views (HKCU only for the current user)
$paths = 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\*',
'HKLM:\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\*',
'HKCU:\Software\Microsoft\Windows\CurrentVersion\Uninstall\*'
Get-ItemProperty $paths | Select-Object DisplayName, DisplayVersion, Publisher, InstallDate, InstallLocation, InstallSource |
Export-Csv E:\case\uninstall.csv -NoTypeInformation
# MsiInstaller install and removal events
Get-WinEvent -FilterHashtable @{LogName='Application'; ProviderName='MsiInstaller'; Id=1033,1034,11707,11724} |
Select-Object TimeCreated, Id, UserId, Message | Export-Csv E:\case\msi.csv -NoTypeInformation
# AppX packages for all users (admin)
Get-AppxPackage -AllUsers | Select-Object Name, PackageFullName, InstallLocation | Export-Csv E:\case\appx.csv -NoTypeInformation
robocopy C:\ProgramData\Microsoft\Windows\AppRepository E:\case\AppRepository StateRepository-Machine.srd* /B
Parsing tools
- Registry Explorer and RegRipper (
uninstallplugin) for offline hives, including deleted keys. - AmcacheParser (Eric Zimmerman) exports
InventoryApplicationand links files to programs viaProgramId. - EvtxECmd with its maps, or Velociraptor
Windows.EventLogs.EvtxHunter, for MsiInstaller events. - Velociraptor
Windows.Sys.Programslists Uninstall entries on live endpoints. StateRepository-Machine.srdis SQLite: open a copy with DB Browser for SQLite and review thePackageand related tables.msiinfo(msitools) or Orca to read the summary information of cached.msifiles, which reveals the original product name.
Investigation tips
- Hunt for remote access and tunneling tools (AnyDesk, ScreenConnect, Atera, TeamViewer, NetSupport, ngrok) and compare against your software baseline. See the remote access tools page.
InstallSourceunder\Downloads\,\Temp\or a drive letter that maps to a mounted image shows how the installer arrived.- Per-user installs in HKCU need no admin rights, which is why they are popular with attackers and why each profile's NTUSER.DAT must be checked.
- A cached
.msiinC:\Windows\Installerwithout a matching Uninstall key points to a removed product; its $MFT dates and summary info tell you what and when. - MSI custom actions run as SYSTEM for per-machine installs; pair install time with new services, kernel drivers and scheduled tasks created in the same minute.
- For evidence of execution of the installed product, move to Prefetch, Amcache file entries and BAM.
Related artifacts
- Amcache.hveAmcache.hve cheat sheet: file and program inventory keys, SHA-1 hashes, PE metadata, timestamps and why an entry alone does not prove execution.
- Windows ServicesWindows services cheat sheet: Services key values (ImagePath, Start, Type, ServiceDll), 7045 and 4697 install events, PsExec traces and pitfalls.
- Registry hivesRegistry hives cheat sheet: SYSTEM, SOFTWARE, SAM, SECURITY, NTUSER.DAT, UsrClass.dat, transaction logs, RegBack, LastWrite times and collection.
- Windows event logs (EVTX)Windows event log cheat sheet: EVTX locations, must-know event IDs for logons, processes, services and log clearing, retention, audit policy and parsing tools.
- Remote access tools (RMM)RMM and remote access tool cheat sheet: AnyDesk, TeamViewer, ScreenConnect and more, their log files, connection IDs, IPs and timestamps, and how to hunt abuse.
- Kernel Drivers (.sys, Driver Services, BYOVD)Kernel drivers cheat sheet: driver services (Type 1/2), event 7045, DriverStore, setupapi.dev.log, Amcache and CodeIntegrity logs to hunt BYOVD and rootkits.
- Prefetch Files (.pf)Windows Prefetch cheat sheet: .pf location per version, run count, the last eight run times, referenced files, retention limits and how to parse.
Glossary terms
- Registry HiveAn on-disk file that backs part of the Windows Registry, such as `SYSTEM`, `SOFTWARE`, or `NTUSER.DAT`.
- Registry key LastWrite timeThe single FILETIME stored in every registry key that records when the key or one of its values was last changed, in UTC.
- Security Identifier (SID)The unique value Windows uses to identify users, groups and computers, such as S-1-5-21-…-1001, found throughout registry, logs and file paths.
- NTUSER.DATThe per-user registry hive stored in each Windows profile and loaded as HKEY_CURRENT_USER, rich in user activity and persistence traces.
- Windows event IDThe number identifying an event type within a given provider; it only has meaning when paired with its provider and log channel.
Guides
- Windows Registry Forensics: Hives, Keys and WorkflowWindows registry forensics in practice: hive files, transaction logs, control sets, LastWrite limits, deleted keys, the keys that matter and RECmd workflows.
- Hunting Windows Persistence: Registry, Tasks, WMI and MoreFind attacker persistence on Windows: Run keys, services, scheduled tasks, WMI, Winlogon, IFEO, COM hijacking and BITS, mapped to MITRE ATT&CK, with tools.
- Evidence of Execution: Prefetch, Amcache, BAM and MoreProve a program ran on Windows, not just existed: Prefetch, ShimCache, Amcache, BAM, UserAssist, SRUM, PCA, WER and 4688 compared, with parsing commands.
- Remote Access Tool Forensics: AnyDesk, TeamViewer and MoreInvestigate abused RMM and remote access tools on Windows: install traces, per-tool logs, session IDs and IPs, file transfers and telling attackers from IT.