Skip to content

Instantly share code, notes, and snippets.

@3rg1s
Last active March 16, 2021 10:46
Show Gist options
  • Save 3rg1s/c58e93a47b511df401da877248ed3bd8 to your computer and use it in GitHub Desktop.
Save 3rg1s/c58e93a47b511df401da877248ed3bd8 to your computer and use it in GitHub Desktop.
Powershell Commands.

list filesystem disks

powershell -c get-psdrive -psprovider filesystem

show hidden folders

dir -Force

get hexdump from a file

cat file.txt | hexdump

connect to host using wirm from powershell

PS /> $pass = ConvertTo-SecureString 'Ab!Q@vcg^%@#1' -AsPlainText -Force
PS /> $cred = New-Object System.Management.Automation.PSCredential('htb\jea_test_account', $pass)
PS /> Enter-PSSession -Computer 10.10.10.210 -credential $cred -Authentication Negotiate
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment