$inf = Get-Content "C:\Windows\inf\oem56.inf" -ErrorAction SilentlyContinue if ($inf -match "\[Manufacturer\]") Select-String -Pattern "^%?\w+%?=").ToString().Split('=')[1] Write-Host "Manufacturer: $manufacturer"
Some oem56.inf files are empty except for a single line – those are broken installers that failed to clean up. Part 3: The Secret Life of oem56.inf This file is part of a paired set . For every oem56.inf , there is a corresponding oem56.PNF (precompiled setup file) in the same folder, plus driver binaries ( .sys , .dll ) in C:\Windows\System32\drivers or a subfolder. oem56.inf
| Snippet in file | Translation | |----------------|-------------| | %Realtek% | Realtek audio or network driver | | %NVIDIA% or %AMD% | Graphics driver leftovers | | %Synaptics% | Touchpad driver | | %VMware% or %VirtualBox% | Virtual machine guest additions | | USB\VID_... | A specific USB device | $inf = Get-Content "C:\Windows\inf\oem56
Part 1: The Artifact If you navigate to C:\Windows\inf (yes, it's hidden by default), you'll see a graveyard of files: oem1.inf , oem2.inf ... all the way up to oem56.inf and beyond. it's hidden by default)