Detection Architecture
BCU employs multiple factory classes that scan different sources concurrently:Registry Factory
Scans Windows registry for standard uninstaller entries
Store App Factory
Detects Windows Store and UWP applications
Steam Factory
Discovers Steam games and applications
Chocolatey Factory
Finds applications installed via Chocolatey
Scoop Factory
Detects Scoop-installed applications
Windows Feature Factory
Identifies Windows optional features
Windows Update Factory
Lists installed Windows updates
Oculus Factory
Finds Oculus VR applications
Directory Factory
Scans Program Files for orphaned apps
Script Factory
Loads predefined uninstall scripts
Registry Detection
The most common detection method scans Windows registry locations where uninstallers are registered.Registry Paths Scanned
Registry Locations
Registry Key Analysis
Required Fields
Required Fields
BCU looks for these essential registry values:
DisplayName- Application nameUninstallString- Command to uninstallDisplayIcon- Application icon pathPublisher- Software publisher/vendorDisplayVersion- Version numberInstallLocation- Installation directoryInstallDate- Installation timestampEstimatedSize- Disk space used (in KB)QuietUninstallString- Silent uninstall command
Optional Fields
Optional Fields
Additional metadata BCU extracts:
URLInfoAbout- Product websiteHelpLink- Support URLInstallSource- Original installer locationModifyPath- Command to modify installationSystemComponent- Hidden system component flagWindowsInstaller- Indicates MSI installationParentKeyName- Parent application reference
Filtering Logic
RegistryFactory.cs
Windows Store App Detection
BCU uses PowerShell to query installed Windows Store applications.Get-AppxPackage Query
Detection Process
Detection Process
- Execute PowerShell
Get-AppxPackagecmdlet - Parse XML or JSON output
- Extract package metadata (name, publisher, version)
- Determine installation scope (user vs. all-users)
- Identify protected/non-removable packages
- Create ApplicationUninstallerEntry objects
Some Windows Store apps are protected and cannot be uninstalled. BCU marks these appropriately.
Steam Application Detection
Steam games are detected by parsing Steam library manifests.SteamFactory.cs
Read Manifests
Parse
.acf manifest files for each game:- App ID
- Game name
- Install directory
- Size on disk
- Last update timestamp
Chocolatey Detection
Chocolatey packages are detected from the Chocolatey package database.Chocolatey Query
Metadata Extraction
Metadata Extraction
For each package, BCU extracts:
- Package name and version
- Install location
- Package metadata (description, author)
- Dependencies
- Uninstall command:
choco uninstall <package> -y
Scoop Detection
Scoop applications are detected by scanning Scoop’s installation directory.Scoop Locations
Windows Features Detection
Query Windows Features
Windows Features are system components and require administrator privileges to modify.
Program Files Orphan Detection
BCU scans Program Files directories to find applications without registry entries.DirectoryFactory.cs
Orphan Detection Logic
Orphan Detection Logic
- Enumerate all subdirectories in Program Files
- Look for common uninstaller executables:
uninstall.exeunins*.exe(Inno Setup)uninst.exehelper.exe --uninstall
- Check if directory has corresponding registry entry
- If no registry entry found, mark as orphan
- Attempt to identify installer type from executables
- Generate potential uninstall command
Concurrent Detection
All factories run concurrently for fast detection:ApplicationUninstallerFactory.cs
Deduplication
Multiple sources may report the same application. BCU uses intelligent deduplication:Matching Criteria
Matching Criteria
Applications are considered duplicates if they match on:
- Exact ProductCode (MSI GUID)
- Display Name + Publisher (fuzzy match)
- Install Location (same directory)
- Uninstall String (same command)
Merging Strategy
Merging Strategy
When duplicates are found:
- Prefer MSI entries over registry entries
- Prefer entries with ProductCode
- Merge metadata from all sources
- Use most complete information available
- Keep QuietUninstallString if available from any source
Performance Optimization
Parallel Execution
All factory classes run concurrently using Task-based parallelism
Caching
Results are cached to avoid repeated expensive operations
Lazy Loading
Additional metadata loaded on-demand, not during initial scan
Registry Batching
Registry reads are batched to minimize I/O operations
Configuration Options
Users can enable/disable specific detection sources:Settings
Related Topics
Uninstaller Types
Learn about different installer systems BCU supports
Helper Tools
Understand the helper applications used for detection
