A SOCKS proxy is very useful in case you want to surf the web securely over an insecure network or behind a very restrictive firewall.

It’s very easy to configure a remote server as a SOCKS proxy, all you have to do is 1) have ssh access to the remote server and 2) execute on a terminal:

ssh -N -C -D 8080 user@remote_server

After that, configure your web browser to use a SOCKS proxy with the following information:

IP: localhost
PORT: 8080

NOTE:
The ssh command shown above don’t return the prompt to the shell, that’s fine; that way it’s easier to terminate the proxy session just hitting Ctrl-C. In case you prefer to run the ssh command in background, you can execute it this way:

ssh -D 8080 -f -C -q -N user@remote_server
Share!