Sometimes, you are connected to an internet which is unknown/insecure such as public WiFi hotspots or you are just surfing the internet at work. In these type of scenarios you might want to secure your connection so no one can sniff at what or where you’re surfing. One way to create a secure connection is to create an SSH tunnel, and have your web browser use it as a SOCKS proxy.
The first requirement is to have a remote host running an SSH server. e.g. a box at home running OpenSSH. Then, you need to have an SSH client installed on your local machine, for Windows you can use PuTTY.
Establish an SSH tunnel using PuTTY:
Create a new PuTTY session
Run PuTTY and create a new session to connect to the remote host. Fill in the hostname, the port (usually 22), make sure SSH is checked.
Configure the Secure Tunnel
Click on “Tunnels” on the left panel to set up dynamic fowarding for a local port. Under “Add new forwarded port” type in the port number (e.g. 4080) for the source port, leave the destination blank, and check Auto and Dynamic. Then click the “Add” button. You should see D4080 listed in the “Forwarded Ports” box.
Establish an SSH tunnel on Linux:
Use the following command:
$ ssh -D 4080 username@remote_host_server
The tunnel is created when you login to the SSH server.
Configuring Your Web Browser:
To use the SSH tunnel as a SOCKS proxy you need to change the connection settings in the browser.
In the Firefox Connection Settings:
- Check “Manual Proxy Configuration:”
- Fill in 127.0.0.1 for the “SOCKS Host:” and 4080 for “Port:”
- Check “SOCKS v5″
Once everything is done you are now surfing the web securely.
Related posts:



Pingback: vincentkong.com » Blog Archive » Surfing the Web using Web Proxy