Networking

Port Scanning

Powershell Ping Sweep

1..20 | % {"192.168.1.$($_): $(Test-Connection -count 1 -comp 192.168.1.$($_) -quiet)"}

Powershell Testing ports

Test-NetConnection -computername UFC-WEBPROD -Port 80

Port Forwarding

# Listen address is local ip of machine that will be proxy, connect address is target
netsh interface portproxy add v4tov4 listenaddress=192.168.250.10 listenport=443 connectaddress=192.168.250.22 connectport=443

Firewalls

Listing Rules

netsh firewall show opmode

Disabling Firewall

netsh firewall set opmode mode=disable

Allowing Rule

Enabling PsRemoting (WinRM)

Enabling CredSSP

Hyper-V

Listing VMs

Get Info on Running VMs

Manage VMs

Mounting VM Disk Image

SMB Null Session

Last updated

Was this helpful?