I need to get all installed Windows updates with PowerShell.
Result should contains update name, KB number, CVE id and severity rating.
I had try next scripts:
Get-HotFix,
wmic qfe list,
Get-WmiObject -Class Win32_QuickFixEngineering.
But it returns only KB numbers.
Also I tried filter installed updates from next script result:
Get-ChildItem -Path 'Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Component Based Servicing\Packages'.
But this script return not all updates.
Next script don't return all installed Windows updates too:
$Searcher = $Session.CreateUpdateSearcher()
$HistoryCount = $Searcher.GetTotalHistoryCount()
$Updates = $Searcher.Search("IsPresent=1").Updates
$Updates | ForEach-Object {$_}
I have no more ideas and I will be grateful for help.