From: Brett =?unknown-8bit?q?Cav=C3=A9?= <brett@nerdsonsite.co.za>
To: lartc@vger.kernel.org
Subject: [LARTC] Port based routing with transparent proxy
Date: Fri, 14 Nov 2003 10:02:05 +0000 [thread overview]
Message-ID: <marc-lartc-106880460103338@msgid-missing> (raw)
Hi all,
I have a RH9.0 system configured as a gateway. I am running squid,
configured for transparent proxy.
I have 3 NIC's - 1 LAN (eth0), 1 with an ADSL (ppp0) via pppoe (eth2,
0.0.0.0) connection, and a leased line (eth1).
I have set up port based routing, using the mangle table with a MARK
target for http and https traffic. The routing works fine until I use
transparent proxy. Is there a way to route traffic coming out of squid
to use the adsl connection?
I have the following rules
iptables -t mangle -A PREROUTING -p tcp -i $LANIF --dport 80 -j MARK
--set-mark 1
iptables -t nat -A PREROUTING -p tcp -i $LANIF --dport 80 -j REDIRECT
--to-port 3128 #if this is commented out, port routing works, if not it
doesn’t.
My default route is a router connected to the leased line interface
(eth1). I have added ip rules and ip routes as documented on the lartc
website (ip rule add fwmark 1 ### etc, and ip route add ### table 201
etc)
I have tried "iptables -t mangle -A POSTROUTING -o ! $LANIF etc" but
this doesn’t work, as expected, as routing has already taken place. Any
suggestions would be appreciated.
Regards
Brett
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
reply other threads:[~2003-11-14 10:02 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=marc-lartc-106880460103338@msgid-missing \
--to=brett@nerdsonsite.co.za \
--cc=lartc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox