Good Day my dear Linux Yogi’s,
in today’s illustration I am going to show you how you can set up a Proxy-chain to surf more anonymous in the Internet. I said more anonymous because I don’t believe that there is a 100% solution to totally stay anonymous on the Internet. If you read this article and believe that we can add even more security and anonymity to this solution please feel free and comment on this blog post or use the contact form to suggest addition to this blog.
So Privoxy is a Proxy Server that will remove advertisements and Tor is a Proxy Server that routes you anonymously through the Tor network to the Internet.
Open up a Terminal windows and elevate your console.
enter your password and now we are root. Before we install anything lets make sure we are up to date with our current system installation. You should always make sure before you install something new that you are on the latest update. Enter the following lines:
apt-get update apt-get upgrade apt-get dist-upgrade apt-get autoremove
now that we are updates lets install the Privoxy and tor package to our system.
apt-get install privoxy tor
after the installation is finished we need to make a few adjustments to our Privoxy configuration file. Lets open up /etc/privoxy/config with you desired editor and uncomment the lines that start with forward-socks and forward and match them like the following lines:
forward-socks4a / 127.0.0.1:9050 . forward-socks4 / 127.0.0.1:9050 . forward-socks5t / 127.0.0.1:9050 . forward-socks5 / 127.0.0.1:9050 . forward 192.168.*.*/ . forward 10.*.*.*/ . forward 127.*.*.*/ .
So what we are doing here is to loop through all our requests to the Tor proxy which by default is listening to port 9050 and also exclude requests that go to 192.168.*.*, 10.*.*.* and 127.*.*.* from going through the Tor Proxy since to does not route those network addresses.
The Privoxy Proxy Server is by default listening on port 8118 which we will use to configure our proxy setting on our local system. This current configuration only allows the local machine to use this proxy which probably is good for most of use but if you plan on using this proxy chain on your network for others to use we need to make another change in this Privoxy configuration file. Look for section 4.1 in the Privoxy configuration file and you should see the following line:
lets adjust this line to the servers static IP address like this:
this now allows the server to listen on his static IP address for request on port 8118 and before it was only listening on its own loopback ethernet adapter.
Ok next we should make a couple of changes in Firefox is you use Firefox. Start up your Firefox browser and in the URL field enter:
now enter the following into the search field:
and then below in the preferences field do a double click on this option in order to change it from false to the value true. Next go back to the search field and enter:
and again double click it to change the value from false to true. That is it can close the browser for now. The last thing we need to do is the tell our system about the proxy server.
Click on the Gear icon
to go to System Settings.
Now in the system settings window click on the Network Icon and you see the following.
Next click on the Network Proxy option
Click on the the Method drop down list and select Manual and fill out the field like it is showing in the screenshot unless you are on a remote machine in your network then you need to change 127.0.0.1 to the IP address of your Proxy Server that we just set up. Now you can close this and your system is using your proxy chain. All browsers are set by default to use system settings for the proxy configuration.
The last thing we should do it to verify that our proxy is actually working and the we use the Tor network. Open up your browser and go to the following URL:
and if everything is working the way it should you should see something similar like the following.
and if it is not going through the Tor proxy it shows you something similar to the following.
Ok my fellow Linux Yogi’s this concludes this illustration. I hope you enjoyed this article. Please subscribe to this blog to support my work and consider to register to the forum to spark some conversation regarding issues you may encounter on your journey during the Linux universe.
Until next time, Namaste my friends! 😉