Created
May 2, 2018 02:32
-
-
Save jermdw/f705adafb3f5158c632b52464d9b6e08 to your computer and use it in GitHub Desktop.
Retrieve unsigned executables in user folders
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(gwmi Win32_UserProfile | ? { $_.SID -notmatch "S-1-5-(18|19|20).*" }).LocalPath | % { ls -Path $_ -Recurse -Filter "*.exe" } | % { Get-AuthenticodeSignature -FilePath $_.FullName } | ? { $_.Status -ne 'Valid' } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment