Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Del Winiecki <delw@wildapache.net>
To: netfilter@lists.netfilter.org
Subject: Reverse SNAT routes out wrong interface
Date: 20 Feb 2003 13:34:46 -0700	[thread overview]
Message-ID: <1045773286.2306.77.camel@thizzy> (raw)

Ok, another challenge.

SNAT works fine, but I need the outside WAN address to look as if it
came from an address on the eth1 network, not the Upstream WAN network.
My linux router ports:

eth4 192.168.1.0/24 ------------ (local offices, admin net)

eth1 209.x.x.x/24 -------- (downstream WAN)

WAN1 64.x.x.x/30 ---------  (upstream provider)

all traffic from 192.168.1.0/24 must look like its from 209.x.x.13

traffic flowing into WAN1 with a destination address of 209.x.x.13
somehow needs to get routed out the eth4 interface and "un-natted"
instead of routing out eth1.

I have:
iptables -t nat -A POSTROUTING -o WAN1 -j SNAT --to 209.x.x.13

Is there some way to use DNAT to fool the kernel routing into properly
routing this?

Thanks,
Del W.



             reply	other threads:[~2003-02-20 20:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-02-20 20:34 Del Winiecki [this message]
2003-02-21  6:36 ` Reverse SNAT routes out wrong interface Joel Newkirk

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1045773286.2306.77.camel@thizzy \
    --to=delw@wildapache.net \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox