A Windows OS reconnaissance tool to perform common enumeration and security checks.
Supported by @swarleysez
PS C:\Windows\Temp> Import-Module .\PSRecon.ps1
- Admin privileges aren't needed for any functions.
- All code written for PowerShell version 2 or higher
- Written for Windows 7 or higher / Server 2008 or higher
Get-HostChecks [-Defense] [-DefenseOnly] [-SkipLocalAdmins]
Get-HostSummary
- summary of general user/host informationGet-HostIPAddress
- IPv4 address of all adaptorsGet-LocalUsers
Get-LocalAdmins
Get-NetVersions
- Discover installed .NET versionsGet-PowerShellVersions
Get-PSExecutionPolicy
- PowerShell execution policy for all scopesGet-PSLogging
- check PowerShell logging status (scriptblock, transcription, module)Get-SMBv1
- SMBv1 enabled or disabledGet-LAPS
- check for existence of Admpwd.dll fileGet-AntiVirus
- Currently only checks for AV products installedGet-MappedDrives
Get-NetShares
Get-UnattendedInstallFile
- checks for file existence in several locationsGet-CachedGPPPassword
- checks for cached Group Policy prefernces 'cpassword'. Also includes scheduledtasksv2 type.
Get-HostChecks -Defense
- Highlight security issues discovered by various checks.
- Useful for blue teams, security engineers, general defenders
Get-HostChecks -DefenseOnly
- Execute only checks that discover potential security issues.
Get-HostChecks -SkipLocalAdmins
- Skips the local admin check
This could be necessary in larger environments with thousands of domain-based groups. The check calls the Win32_GroupUser class, which will query all domain groups as well as local ones.
Future additions will include:
- Add comment-based help for all functions
- Domain-based checks
- Remote host execution
- Anti-virus status (real-time protection, exceptions list, date of definitions, etc.)
- EDR products (CarbonBlack, Bit9, etc.)
- GPPPassword on domain controller(s)
- SMB signing status (none, enabled, required)
- Built-in port scanner (stripped down version of Nmap)
- Proxy settings
- A filtered list of listening or established ports
https://github.com/PowerShellMafia/PowerSploit
https://github.com/dafthack/HostRecon