Port Forwarding under Mandrake /w iptables
I'm using Mandrake 8.2 with iptables and not those weird $IPTABLES thingy I've been seeing a lot of. Just what are they anyways?
My problem is that I want to forward port 6112 from the outside world to 192.168.1.3 (both are using eth0). What exactly do I need?
My current config consists of:
modprobe iptable_nat
echo 1 > /proc/sys/net/ipv4/ip_forward
#[Basic Routing]
/sbin/iptables -t nat -A POSTROUTING -s 192.168.1.0/24 -j MASQUERADE
THAT'S IT!! It works for anything the windows client use, like ICQ, Web browsingm, etc. But if I were to foward a port 6112, I was told that I need DNAT for incomming and SNAT for outgoing. Also one more question: Can I forward 1 port over a range of internal IPs? Just what would happen if it does work? And is it possible for a packet that is forwarded to port 6112 be redirected to EITHER of the many windows client that is connected to the Linux box? (eg, 2 different windows clients uses port 6112 to contact with the outside world, any way to modify the incomming packets, headers, etc so it fowards to client 1 or client 2 accordingly?)
Thanks a bunch!!
|