How to Set Up a Proxy Server in Ubuntu
If you are an internet savvy person who likes exploring new options or discovering new cool internet possibilities, then you are probably aware of Ubuntu Servers and the transparent proxies. Setting up a proxy in Ubuntu is useful to businesses that offer internet to clients or public, or even to individuals who leave their own network on. This way, you can always be aware of the ways the Internet connection is used for and by whom. Additionally, proxy servers permit users to surf to websites that may not be accessible through their normal Internet connections.
Instructions
-
-
1
Download and install the Squid Transparent Proxy on your Ubuntu System from the reference listed in the resources.
-
2
Edit the Ubuntu configuration file to include the following line of code that references the squid proxy installation: udo vi /etc/squid/squid.conf
-
-
3
Configure the host for the Ubuntu server to access the IP ranges for the proxy server. The configuration lines to update the host configuration file are:
acl internal_network src 192.168.0.0/24 (this is the IP range of your server)
acl localnet src 127.0.0.1/255.255.255.255
http_access allow our_networks
http_access allow localnet -
4
Install the Apache2 utilities to authenticate the proxy installation and add users for the proxy with the following Ubuntu commands. The Apache2 Utilities do not need to be downloaded separately (they are already resident on the server).
sudo aptitude install squid squid-common apache2-utils
sudo htpasswd -c /etc/squid.passwd first_user
sudo htpasswd /etc/squid.passwd another_user -
5
Set the authentication parameters for the proxy server with the following Ubuntu commands and restart the server to make the proxy service live.
auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid.passwd
auth_param basic children 5
-
1