Skip to content

Latest commit

 

History

History
20 lines (15 loc) · 1.23 KB

SSH.md

File metadata and controls

20 lines (15 loc) · 1.23 KB

Tunneling - Using SSH as a "proxy/vpn"

Route all traffic for a specific port through an SSH tunnel. Could be useful when you wish to access websites that are behind firewalls or similar. Just configure your browser to proxy all traffic through machine.com using port 1337 and SOCKS-5. More details here

ssh -D 1337 [email protected]

Stealthy & secure connect

ssh -o -T UserKnownHostsFile=/dev/null [email protected] bash -i -4 -C -c blowfish-cbc
  • The -T flag prevents a TTY from being allocated upon login. There are some technical issues that arise regarding not using a TTY (some commands not outputting properly and some programs not working as intended) Read more about it here.
  • The bash -i flag will simulate a prompt for you, since the lack of a TTY will mean no prompt
  • The -o flag alongside setting UserKnownHostsFile to /dev/null will result in nothing being logged to known_hosts when you connect.
  • -4 will force IPv4 connectivity
  • -C will compress the stream cipher
  • -c blowfish-cbc will specify ‘blowfish’ for the encryption type for stream cipher