NAT rules for Multiple IPAddresses on same physical interface

Aseem Rastogi aseem at india.tejasnetworks.com
Mon Oct 17 12:44:34 CEST 2005


Hi All,

I have a situation where my machine has one ethernet interface but i 
have assigned it multiple ipaddresses on same interface. Now I want to 
add some NAT rules so that a packet destined for my machine and port 
3023 is redirected to some other IP and port.

Do I need to write rules for each of the IPAddresses that my machine 
has? Or is there a way in NAT PREROUTING to identify if this packet is 
for localhost (Of course something other than --destination)? I do not 
want to write rules for each IPAddress, rather I am looking for a way to 
identify if this packet is for me.

Thanks in advance,

Regards,
Aseem.

-- 
The end is always good. If it's not good, it's not the end.






More information about the netfilter mailing list