Re: IPTABLES port forwarding woes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hmmm.. Follow up question to this. How would the outgoing connection back to the internet find it's way back to the remote internet host, if the source address was re-written to machine 1 when in came in to begin with? Wouldn't the original remote internet source address be lost in all the translation?

Thanks for your insight by the way!

-erich

Pascal Hambourg wrote:
Erich Weiler a écrit :

Ah, I forgot to mention, machine 2 is on a private network that is not
routed in any way.  So, there is no default gateway for machine 2...
That's why I was thinking the source port would have to be re-written
internally such that machine 2 would know to send it back through
machine 1 and then on to the internet... ?

Then indeed you need to SNAT the forwarded connection. Also make sure that machine 1 has IP forwarding enabled.
--
To unsubscribe from this list: send the line "unsubscribe netfilter" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe netfilter" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux