hi there...

I'm trying to configure my box with iptables to port forward to a
mailserver. The 'gateway' machine has a satellite connection, and all
the iptable setups I've tried get freaked out at the fact that traffic
(generally) comes in on one interface(satellite), and out on the other
(ppp0).  Im wondering how I could convince it to instead ignore which
interface the traffic is comming in on (sm200d,ppp0, lo or eth0), and
just route the packets.

here's the offending rule(s)

/sbin/iptables -t nat -A PREROUTING -i ! eth0 -p tcp --dport 25 -j DNAT 
--to-destination 192.168.0.2:25

I put the ! eth0 in the hope that it would just forward any packets 
interfaces other than eth0.  I first off attempted to specify a source 
ip address(s) but since the satellite is 10.0.0.1 and the modem has my 
static ip (according to ifconfig).

below are the other two rules.  I was a little aprehensive about using 
'-o ppp0 ' but then realised that is definetly the only way for traffic 
to get out on the internet.  incomming is different as traffic from my 
uplink provider comes down the modem, but everything else is satellite.

/sbin/iptables -t nat -A POSTROUTING -o ppp0 -j MASQUERADE
/sbin/iptables -A FORWARD -i eth0 -j ACCEPT


any help would be appreciated =)

da!!as

-- 
----------------------------------------
dallas baird - Australia Zoo sys admin
     http://www.crocodilehunter.com.au/
        [EMAIL PROTECTED]
        reception (+617) 5494 1134
        direct    (+617) 5436 2011
Conservation through exciting education!
-----------------------------------------





-- 
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]?subject=unsubscribe
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to