help with iptables

John Van Ostrand john-Da48MpWaEp0CzWx7n4ubxQ at public.gmane.org
Fri Jan 19 16:54:06 UTC 2007


On Fri, 2007-01-19 at 10:56 -0500, Dave Cramer wrote:

> So what I'd like to do is  using iptables :
> 
> 
> route port 25 traffic currently going to B --> A except when it comes
> from A

You have two options. 

If the port 25 traffic that you want to NAT is always coming in from one
interface and system A is on another then use the --in-interface
iptables option to specify the external interface.

If you can't differentiate based on interface then you'll have to go to
policy routing. See iproute2 to create a separate routing table for the
traffic. You may also need to use iptables MANGLE table to mark packets.


-- 
John Van Ostrand
         Net Direct Inc.
 
CTO, co-CEO
564 Weber St. N. Unit 12
   Waterloo, ON N2L 5C6 
 map 
john-Da48MpWaEp0CzWx7n4ubxQ at public.gmane.org
        Ph: 519-883-1172
 ext.5102
Linux Solutions / IBM
Hardware
        Fx: 519-883-8533
 

--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list