Requesting Direction regarding iptables
From: Brad S (brad_at_akwwc.com)
Date: 07/29/04
- Next message: Robert: "Advice requested: Porting Linux TCP/IP stack to application space"
- Previous message: Mark Richards: "help with simple NAT forwarding"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 28 Jul 2004 15:05:06 -0700
Hello, thanks for taking the time to read my msg.
I am trying to setup my iptables to use squid as the gateway for the
network (which looks like)
http://www.garnessengineering.com/images/currentconfig.gif
To get my cards to interact as a gateway I use the commands.
iptables --table nat --append POSTROUTING --out-interface eth1 -j
MASQUERADE
iptables --append FORWARD --in-interface eth0 -j ACCEPT
This allows my client machines to connect to the 149.0.0.1 gateway and
use the 192.168.0.1 gateway to communicate with the internet. I need
the http traffic to be routed through the squid proxy, prior to being
sent out to the router.
In the squid faq they give this command (BELOW) in order to use squid
as the gateway proxy. I tried implementing this with no sucess, I
think i am close, but some expert direction would be greatly
appreciated.
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT
--to-port 3128
I am using linux slackware current, squid 2.5 & my kernel has support
for masqurading and iptables configured. I just am not sure which
iptables commands to use in my startup script to configure my network.
I really appreciate it thanks alot. yikes iptables is confusing and
intimidating, but I think i can get it with some direction.
Brad Garness
- Next message: Robert: "Advice requested: Porting Linux TCP/IP stack to application space"
- Previous message: Mark Richards: "help with simple NAT forwarding"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|