[mdlug] Need an iptables rule for bypassing a proxy
Jim Broughton
jbroughton at twmi.rr.com
Fri Dec 31 19:08:18 EST 2010
On 12/29/2010 06:34 PM, Jeff Hanson wrote:
> I've got DansGuardian on 8080 -> Squid on 3128. Firefox is set to use
> 8080 as its proxy. I need a rule to bypass DG and connect to Squid
> directly. I tried this but it doesn't work:
>
> iptables -t nat -A PREROUTING -i lo -p tcp --dport 8080 -j REDIRECT
> --to-port 3128
>
> Didn't work with eth0 either. Firefox reports it doesn't get a
> response from the proxy.
>
> The idea here is to bypass DG without having to change Firefox's proxy settings.
>
> (I tried to post this to the mailing list at lugwash.org but their
> server is down again.)
> _______________________________________________
> mdlug mailing list
> mdlug at mdlug.org
> http://mdlug.org/mailman/listinfo/mdlug
>
I think if you replace the -i lo with -s 192.168.0.x (or whatever you use as the
machines IP address) you should be all set.
The iptables command you have in your email executes with "-i lo" replaced
with "-s 192.168.0.24" (my machines local ip address for eth0) and returns
no errors. Give it a shot.
Of course I may be wrong but give it a try. If not we'll try something else.
Jim
More information about the mdlug
mailing list