Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Aki Karjalainen <akarjala@sci.fi>
To: netfilter@lists.netfilter.org
Subject: IPTables design question (nat)
Date: 01 Nov 2002 21:41:34 +0200	[thread overview]
Message-ID: <1036179693.23663.10.camel@localhost.localdomain> (raw)

Hi.

I've got a question about IPTables.

Let's say I want to "hide" a public IP pool (e.g. 144.50.50.0/24) behing
NAT. Easy.

Let's say I want to provide SMTP port from LAN to the outside world. I'd
say "-t nat -A PREROUTING -p tcp -d FWexternalIP --dport smtp -j DNAT
--to 144.50.50.12:smtp".

Ok, I'd still have to allow the connection in the BAD-GOOD chain for
this to work.

The result is that the outside world sees the smtp port from the
firewall external IP _as well as_ directly from 144.50.50.12. 

The question is how to hide 144.50.50.12:smtp but still allow firewall
external ip:smtp (DNATted port)?


Summary: How to DNAT some port and still hide the destination IP+port in
the case the real destination IP is a public IP address?




             reply	other threads:[~2002-11-01 19:41 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-01 19:41 Aki Karjalainen [this message]
2002-11-02 13:00 ` IPTables design question (nat) Antony Stone

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=1036179693.23663.10.camel@localhost.localdomain \
    --to=akarjala@sci.fi \
    --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