Tuesday, June 14, 2011

SSH + SOCKS Proxy

The easiest way to circumvent a filtering gateway is to send all your data encrypted. If you have access to an openssh server, you can easily create a SOCKS proxy by using -D flag in the openssh client and send your data through it:

ssh -D 8080 username@your-server

This command creates a tunnel between your machine and your-server on port 8080. To be able to use this tunnel to send your data, you should also configure the proxy setting in your browser. To do this in Firefox, for example, go to Edit -> Preferences -> Advanced -> Network -> Connection setting, select Manual proxy configuration, and in the SOCKS Host text box, enter your local address, e.g., 127.0.0.1, and in the Port text box, enter the port number you had used in the ssh command, e.g., 8080 in our example.

No comments: