Skip to content

Powershell tidbits

TheGetch edited this page May 14, 2021 · 2 revisions

List Drives

get-psdrive -psprovider filesystem

Bypass Execution Policy

https://blog.netspi.com/15-ways-to-bypass-the-powershell-execution-policy/

Scenario: Workstation COE with local admin rights

  1. Set the ExcutionPolicy for the CurrentUser Scope via the Registry
  • In this example I’ve shown how to change the execution policy for the current user’s environment persistently by modifying a registry key directly. HKEY_CURRENT_USER\Software\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell 4bd3052bbb3eae0b10bce69ea66ebb3c.png

#powershell

_Sidebar

1. Recon

Ping Sweep

CIDR to IP

2. Enumeration

Services

05. HTTP (80,443,8080,8443,etc.)

3. Exploitation

4. Post Exploiation

5. High Value Information

Hashes

6. Reporting

7. Random Notes/Useful Tidbits

Clone this wiki locally