From: Ben Goedeke <goedeke-netfilter@gmx.net>
To: netfilter@lists.netfilter.org
Subject: NATed and direct connection to one server
Date: Tue, 17 Feb 2004 20:29:18 +0100 [thread overview]
Message-ID: <40326B8E.10303@gmx.net> (raw)
Hey everybody,
I just took over administering a LAN at a university site and I have to
move an entire subnet from private to regular IPs. Up until now the only
outside access to this net was a pop and an smtp server both of which
the users accessed through the firewall's _IP_ address (there was no DNS
entry). There were two NAT rules that forwarded the ports to the real
servers.
To make the move as painless as possible for the users I want to keep
the DNAT rules for a while (and point them to the new IP of the mail
servers). I also added DNS entries for the real IPs of the mail servers.
In the long run I want to drop NAT altogether but for now the mail
servers should be reachable via both the firewall and their own
addresses. Because I doubt everybody will immediately change their mail
client'ss settings.
Now for my question: Do I need to add an SNAT rule in POSTROUTING to
handle responses from the mail servers or is it enough to have the DNAT
rules in PREROUTING? And if I indeed need an SNAT rule how can I
possibly distinguish packets that belong to connections that were DNATed
when they came in and those that weren't and had the right destination
IP all along?
I feel like I'm making a simple thing very complicated here... but I
only have limited experience with iptables. So any help is greatly
appreciated.
Thanks,
Ben
next reply other threads:[~2004-02-17 19:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-17 19:29 Ben Goedeke [this message]
2004-02-17 19:49 ` NATed and direct connection to one server Antony Stone
2004-02-17 20:33 ` Ben Goedeke
2004-02-17 20:45 ` 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=40326B8E.10303@gmx.net \
--to=goedeke-netfilter@gmx.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 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.