This is just a small tutorial on setting up a squid proxy on your Ubuntu box/server. I'm sure there are many better tutorials out there like this. No harm in spreading the knowledge. My intentions were to watch some Streaming tv shows on the BBC's website, turns out you need to be in the UK to avail of such services. Thinking my server was in the UK, here is how I went about finding a solution.
Port forwarding is awesome and allows anyone to appear at the location of their server while they browse online anywhere in the world. Bypassing such things as the great FIREwall of China.
First you need to install squid... sudo apt-get install squid ought to do it. I want to set it up so only my localhost(my server) can access it. Next you'll need to sudo vim /etc/squid/squid.conf to edit the config file.
The first thing I wanted to change was the default port that squid ran on. By default squid will listen on all interfaces. For security reasons, its better to put it on your local network only. To do this I changed the default http_port 3128 to http_port . Next I changed visible_hostname to whatever I wanted. (ie. visible_hostname maksquid).
Next I searched for acl CONNECT method CONNECT and added the line acl maknet src underneath it. This is a group called maknet and they are the only ones allowed access. I then found the line http_access allow localhost and added the line http_access allow maknet beneath. It is also important to make sure http_access deny all is set.
I then saved everything and restarted squid using the command sudo /etc/init.d/squid restart. Everything seemed to be running fine and their were no errors. Next I wanted to port-forward my local firefox (on my laptop) to my distant server/proxy and allow me to watch these damn TV shows. To do this you can use . This will bind your localhost to the remote server. You'll need to provide your password like a regular login. Then you should set your Firefox proxy to localhost port 666.
It should all work now! So I load up my Firefox and enter in google.com to the search bar. BAM. google.fr... Turns out my server isn't in the UK at all. FML. At least you now know how to set up squid ;)
hax brah