IT4510 @ utahtech
For this assignment, you will need to minimally use your ubuntu vm instance to install the proxy programs and some vm instance that has a browser to test if the proxy is working correctly.
filterport
in the e2guardian.conf file). Squid and e2guardian should be on the same machine.sudo ufw disable
or sudo ufw stop
(It may already be disabled)/var/log/squid/access.log
. If you connect to port 3128, only the squid rules will be processed. If you connect to 8282, e2guardian will process its’ rules first and then will forward onto squid.sudo service squid3 restart
to make them take effect.You can see some screenshots as to how to begin this assignment here.
Remember to make sure that you are TASTEFUL. We need not experiment with any questionable sites to test our rules.
sudo apt-get install squidguard
/etc/squid/blacklists/
edit /etc/squidguard/squidGuard.conf
(to contain only this)
dbhome /var/lib/squidguard/db
logdir /var/log/squidguard
dest bad{
domainlist /etc/squid/blacklists/bad/domains
}
acl {
default {
pass !bad all
redirect http://localhost/blocked.html
}
}
localhost
above, to the ip of your squid machine… (Really, it just needs to be pointed to any web server that has the blocked message you want).. I installed apache2 on my squid server and created /var/www/html/blocked.html
with some content in it, and reloaded squid.Note that it is looking for the bad/domains
file. (I created this, but you could point it to any of those that are in your blacklists directory. You could look in any of those blacklist directories to see how they are structured).
Add an entry at the end of squid.conf
url_rewrite_program /usr/bin/squidGuard -c /etc/squidguard/squidGuard.conf
Proxies are VERY exploitable from malicious do-badders on the internet. Make sure that you are listening at the port above. When I have marked off your assignment score, please disable your proxy.