Linux Netfilter discussions
 help / color / mirror / Atom feed
From: "Vernon A. Fort" <vfort@provident-solutions.com>
To: netfilter@lists.netfilter.org
Subject: Re: Redirect Command
Date: Thu, 21 Apr 2005 08:58:21 -0500	[thread overview]
Message-ID: <4267B17D.5000700@provident-solutions.com> (raw)
In-Reply-To: <327bfad305042106267479b9@mail.gmail.com>

Hernan Arredondo wrote:

>Hi all,
>
>I'm new with iptables, I trying to create a rule that redirect all the
>packets that goes to the port 25 of my firewall to the port 25 in a
>Internet LAN machine, then I execute the command:
>
>/sbin/iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 25 -j DNAT
>--to 192.168.10.12:25
>
>eth0 is the host exposed directly to Internet, and 192.168.2.12 is the
>host in the LAN.
>  
>
You should also have a FORWARD rule:
    /sbin/iptables -A FORWARD -p tcp -d 192.168.10.12 --dport 25 -j ACCEPT

Vernon


      parent reply	other threads:[~2005-04-21 13:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-21 13:26 Redirect Command Hernan Arredondo
2005-04-21 13:41 ` Jason Opperisano
2005-04-21 13:58 ` Vernon A. Fort [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=4267B17D.5000700@provident-solutions.com \
    --to=vfort@provident-solutions.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