From: "Ryan Beisner" <ryanb@thedataarc.com>
To: netfilter@lists.netfilter.org
Subject: DMZ Scenario
Date: Thu, 14 Nov 2002 18:33:45 -0600 [thread overview]
Message-ID: <000c01c28c3e$ab3603a0$64dc0a0a@i> (raw)
[-- Attachment #1: Type: text/plain, Size: 1762 bytes --]
Hi
I have successfully installed a mail + web server in my new dmz, filtered by netfilter in Redhat 7.3. My problem is, the request addresses show up as the dmz interface's ip address (of the packet filter box). This presents a problem with Sendmail, Postfix, Apache, etc. for logging and security purposes. For instance, to allow Postfix to relay for your specific IP range, it won't work because Postfix & Sendmail see xxx.xxx.177.25 as the originating IP.
So, the effect is that EVERYONE can relay through the box ... uh oh! I've temporarily moved it back into the real world with it's own iptables script. For lots of reasons, I want it in the DMZ.
Is there a way to forward packets without MASQing? I think that's what I need to do here. All help is appreciated. Thanks!
ps. You'll notice that right now I'm allowing ALL traffic to/fro these two DMZ ip's. I plan to tighten that up later.
.
.
.
.
xxx's = external IPs
...............
PRESext=xxx.xxx.177.24
KEYext=xxx.xxx.177.25
PRESdmz=10.10.177.24
KEYdmz=10.10.177.25
$ipt -A FORWARD -s 0/0 -d $PRESext -j ACCEPT
$ipt -A FORWARD -s $PRESext -d 0/0 -j ACCEPT
$ipt -A FORWARD -s 0/0 -d $PRESdmz -j ACCEPT
$ipt -A FORWARD -s $PRESdmz -d 0/0 -j ACCEPT
$ipt -A PREROUTING -t nat -d $PRESext -j DNAT --to $PRESdmz
$ipt -A POSTROUTING -t nat -d $PRESdmz -j SNAT --to $PRESext
$ipt -A FORWARD -s 0/0 -d $KEYext -j ACCEPT
$ipt -A FORWARD -s $KEYext -d 0/0 -j ACCEPT
$ipt -A FORWARD -s 0/0 -d $KEYdmz -j ACCEPT
$ipt -A FORWARD -s $KEYdmz -d 0/0 -j ACCEPT
$ipt -A PREROUTING -t nat -d $KEYext -j DNAT --to $KEYdmz
$ipt -A POSTROUTING -t nat -d $KEYdmz -j SNAT --to $KEYext
...............
.
.
.
.
.
.
TIA
-Ryan Beisner
===linux everywhere===
[-- Attachment #2: Type: text/html, Size: 3624 bytes --]
next reply other threads:[~2002-11-15 0:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-11-15 0:33 Ryan Beisner [this message]
2002-11-15 1:29 ` DMZ Scenario Joel Newkirk
2002-11-15 2:57 ` ryan @ thedataarc
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='000c01c28c3e$ab3603a0$64dc0a0a@i' \
--to=ryanb@thedataarc.com \
--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