Latest Windows Security Updates in PowerShell

Microsoft releases Windows updates and security updates every month of second Tuesday to fix the vulnerable’s and loopholes in the Windows Server Operating system. The requirement is to find the latest Windows security updates installed with hotfix ID and installation date.

To find the latest installed security update, WMI Class Win32_QuickFixEngineering was helpful to find the relevant security and hotfix installed information.

One line PowerShell  Code
Get-WmiObject -class Win32_QuickFixEngineering | where { (($_.InstalledOn -match '2014') -and ($_.Description -match 'Security')) } | select -property Description, HotFixID, InstalledOn | Format-Table -AutoSize

security update

I piped the output of Win32_QuickFixEngineering to where-object which finds the matches for the installed date, description, and more piping to select the properties with formatting output.