All of lore.kernel.org
 help / color / mirror / Atom feed
* iptables NAT with "policy routing?"
@ 2004-01-22  6:49 Brian Capouch
  2004-01-27  1:47 ` Harald Welte
  0 siblings, 1 reply; 2+ messages in thread
From: Brian Capouch @ 2004-01-22  6:49 UTC (permalink / raw)
  To: netfilter

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.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-01-27  1:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-01-22  6:49 iptables NAT with "policy routing?" Brian Capouch
2004-01-27  1:47 ` Harald Welte

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.