From: Jason Opperisano <opie@817west.com>
To: netfilter@lists.netfilter.org
Subject: Re: server in DMZ
Date: Thu, 02 Sep 2004 09:13:25 -0400 [thread overview]
Message-ID: <1094130804.2573.9.camel@wolfpack.ljm.dom> (raw)
In-Reply-To: <20040902040821.GA12641@tranquility.scriptkitchen.com>
On Thu, 2004-09-02 at 00:08, Payal Rathod wrote:
> On Wed, Sep 01, 2004 at 11:54:55PM -0400, John A. Sullivan III wrote:
>
> > I think you have confused the issues. Do not put the source match in
> > the PREROUTING rule (thus your squid access from the local LAN will not
> > break). Do put the source match in the FORWARD rule. That will
> > restrict outside access to only 1.2.3.4. I assume there is already a
> > FORWARD rule that allows access from the LAN. Hope this helps - John
>
> So, you mean I keep the PREROUTING rule as before and make
> -A FORWARD -d 10.10.10.3 -p tcp -m tcp --dport 80 -j ACCEPT
> to
> -A FORWARD -s 5.6.7.8 -d 10.10.10.3 -p tcp -m tcp --dport 80 -j ACCEPT
>
> But will this not forward requests from my squid proxy server too?
>
> -Payal
i think there's some confusion here...there are three rules involved in
this scenario:
(1) NAT rule that maps port 80 on the outside to port 80 on your DMZ
server:
-A PREROUTING -d 5.6.7.8 -p tcp -m tcp --dport 80 \
-j DNAT --to-destination 10.10.10.3
(2) FILTER rule that allows external access to server in DMZ from client
IP:
-A FORWARD -p tcp -s 1.2.3.4 -d 10.10.10.3 --dport 80 -j ACCEPT
(3) FILTER rule that allows squid proxy running directly on your
firewall to fetch content from server in DMZ:
-A OUTPUT -p tcp -d 10.10.10.3 --dport 80 -j ACCEPT
remember: packets passing through the firewall are filtered by FORWARD,
packets coming from the firewall are filtered by OUTPUT.
-j
--
Jason Opperisano <opie@817west.com>
next prev parent reply other threads:[~2004-09-02 13:13 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-02 2:50 server in DMZ Payal Rathod
2004-09-02 3:04 ` Jason Opperisano
2004-09-02 3:17 ` Payal Rathod
2004-09-02 3:24 ` Jason Opperisano
2004-09-02 3:51 ` Payal Rathod
2004-09-02 3:54 ` John A. Sullivan III
2004-09-02 4:08 ` Payal Rathod
2004-09-02 4:21 ` John A. Sullivan III
2004-09-02 13:13 ` Jason Opperisano [this message]
2004-09-02 19:04 ` Payal Rathod
2004-09-02 19:17 ` Jason Opperisano
2004-09-02 3:05 ` John A. Sullivan III
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=1094130804.2573.9.camel@wolfpack.ljm.dom \
--to=opie@817west.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