📝How-to: Create a SOCKS proxy with SSH

tags

how-to

To start such a connection, run the following command in your terminal.

$ ssh -D 1337 -q -C -N user@ma.ttias.be

What that command does is:

    -D 1337: open a SOCKS proxy on local port :1337. If that port is taken, try a different port number. If you want to open multiple SOCKS proxies to multiple endpoints, choose a different port for each one.
    -C: compress data in the tunnel, save bandwidth
    -q: quiet mode, don’t output anything locally
    -N: do not execute remote commands, useful for just forwarding ports
    user@ma.ttias.be: the remote SSH server you have access to