There are a number of reasons why you might want to use Squid in transparent mode, I won’t go into them – I’ll just explain how!
In Squid versions before 2.6, you’ll want to edit your configuration to specify:
In 2.6 versions and beyond, you can append ‘transparent’ to the end of your http_port option, i.e.:
Squid will now be ready for transparent proxying. Now create some iptables rules to push all outbound port 80 traffic through squid:
eth0 is the local side of your router, –dport 80 specifies a destination port of 80 (HTTP) and we’re going to redirect it to 3128 where your Squid proxy runs.
Tags: iptables, redirect, squid, transparent proxy
[...] These are the same type of rules used to configure transparent proxying for Squid. [...]