From: Antony Stone <Antony@Soft-Solutions.co.uk>
To: netfilter@lists.samba.org
Subject: Re: 3 outside networks
Date: Mon, 17 Jun 2002 19:22:45 +0100 [thread overview]
Message-ID: <200206171822.g5HIMlA13809@Networker.rockstone.co.uk> (raw)
In-Reply-To: <200206171813.g5HIDoA13300@Networker.rockstone.co.uk>
On Monday 17 June 2002 7:13 pm, Antony Stone wrote:
> On Monday 17 June 2002 3:34 pm, Srinath Mantripragada wrote:
> > I have one inside net 172.16.0.0/24 and 3 outside nets 10.28.0.0/16 ,
> > 172.18.0.0/24 and Internet.
> > The 3 nets are routed by one router that i do not have control.
> >
> > I have valid internet Addresses and i want to use NAT with one of them
> > but not for 10.28 and 172.18 networks.
> >
> > I guess that i need something like : "-d ! 10.28.0.0/16 OR !
> > 172.18.0.0./24"
> > but i dont know how to do that.
>
> Try this:
>
> iptables -A POSTROUTING -t nat -d 10.28.0.0/16 -j ACCEPT
> iptables -A POSTROUTING -t nat -d 172.18.0.0/24 -j ACCEPT
> iptables -A POSTROUTING -t nat -j SNAT --to a.b.c.d
Ooops ! That last one should inlcude the interface name too:
iptables -A POSTROUTING -t nat -o eth1 -j SNAT --to a.b.c.d
Antony.
prev parent reply other threads:[~2002-06-17 18:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-17 14:34 3 outside networks Srinath Mantripragada
2002-06-17 18:13 ` Antony Stone
2002-06-17 18:22 ` Antony Stone [this message]
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=200206171822.g5HIMlA13809@Networker.rockstone.co.uk \
--to=antony@soft-solutions.co.uk \
--cc=netfilter@lists.samba.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