• We had to restore from a backup today after a failed software update. Backup was from 0000 EDT and restored it at 0800 EDT so we lost about 8hrs. Today is 07/20/2024. More info here.

Secure Web Browsing Using Proxy SOCKS



Ever been at the local coffee shop and didn't trust the public Wi-Fi? Maybe you were on someone random open network that you didn't trust? Or perhaps you're just at work and you do not want the boss knowing what you're doing online. Whatever the case may be, there will probably come a time where you want to take your surfing off the record. This quick how to will describe how to set up a Proxy SOCKS using a Linux VPS and SSH. I first want to point out that if you wish to use Windows as the surfing box, the box you'll be browsing the web from, you'll need Cygwin with OpenSSH installed. Without further ado, lets begin!

Step 1

Make sure you have a Linux VPS or a Linux box at home that you can access via SSH. This tutorial will NOT go into setting up SSH, but for flavors such as Debian you can pretty much do apt-get install openssh and then open port 22 on your firewall/router. If you can SSH into this remote box, that exists outside of the network you do not want tracking you, you're set with step 1!

Step 2

On your surfing box you'll need to be able to SSH. If you're using a Linux machine, you can just pop open a terminal and be set. If you're on Windows I recommend Cygwin (I have not tried this using PuTTY, but feel free to do so). Fire up a terminal and type the following:

ssh -ND 9999 [email protected]

To break this down for you. ssh is just telling the terminal that you are calling the ssh command. The second part -ND tells it you want to stop the terminal after authentication (once you type your password the terminal will appear to hang...you want this) and let you specify a port. We'll be operating over port 9999. The last part is going to be your_user_name@your_host.com

Step 3

Open your browser. In this instance we will use FireFox. Go to Options -> Advanced -> Network Tab. You'll see a sentence that says: Configure how FireFox connects to the internet. Next to it is a Settings button. Click that. Select the Manual Proxy radio. In the SOCKS Proxy field put in your host, in this case localhost, and the port...this will be the 9999 we used during the SSH command.


That's it! Now everything you do from your FireFox browser will first pass through your remote server. The only thing left is to make sure you aren't tracking cookies or internet history on your computer, in case the computer is stolen. You can also do this for many popular IM Clients. I use Trillian and I have mine pass through the same SOCKS as well.

Very important info, I use the methods above rather than using Hotspot Shield. I noted that HS was not really that secure. But setting up my own had many more benefits, including being able to bypass some Cloud securities.
I personally use Tor for this but if you want a single proxy route (or set up some trickery on the SSH's end) it can be just as well. :)