iptables NAT with "policy routing?"

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

 



I have had to temporarily use a table-based route for one of my networks for administrative reasons, e.g.

> ip rule from 192.168.1.0/24 lookup table temp

Then

> ip route add default via 192.168.127.1 dev eth0 table temp

I have standard iptables NAT rules for a host on that network:

iptables -t nat -A POSTROUTING -s 192.168.1.10 -j SNAT --to-source A.B.C.D

iptables -t nat -A PREROUTING -d A.B.C.D -j DNAT --to-destination 192.168.1.10

**********

I suspect though, that this mode of routing (as opposed to using the "regular" table via "route add default") is somehow hosing my iptables NAT?

At least sniffing the egress interface now shows the traffic heading out with its NATted address of 192.168.1.10.

Newbie here, I guess. Can someone help/enlighten?

Thx.

B.


[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