Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Jim Laurino <nfcan.x.jimlaur@dfgh.net>
To: netfilter@lists.netfilter.org
Subject: Re: Port forwarding not working
Date: Sun, 29 Apr 2007 10:39:54 -0400	[thread overview]
Message-ID: <1177857594l.3596l.2l@soapy> (raw)
In-Reply-To: <000c01c78a5f$3d392570$dededede@neilhp> (from +nfcan+jimlaur+ce6b708e36.neil#JAMMConsulting.com@spamgourmet.com on Sun Apr 29 09:06:44 2007)

On 04/29/2007 09:06:44 AM, Neil Aggarwal - neil@JAMMConsulting.com wrote:
> Jim:
> 
> > Maybe you could use SNAT to make the packets appear
> > to come from the firewall, then they ought to come back. 
> 
> How do I set up the SNAT rule?
> 

This will make the packet look like it came from the firewall:

/sbin/iptables -t nat -I POSTROUTING -o eth1 -d $LINKSYS_VPN_IP \ 
  -p tcp --dport 1723 -j SNAT --to-source 192.168.1.1

(where 192.168.1.1 is the ip address of the firewall on eth1 side)

If postrouting still has a default drop policy etc.
then this rule must be found before the accept rule,
that is why it has -I, to put it first.

HTH
-- 
Jim Laurino
nfcan.x.jimlaur@dfgh.net
Please reply to the list.
Only mail from the listserver reaches this address.



  parent reply	other threads:[~2007-04-29 14:39 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-29  3:15 Port forwarding not working Neil Aggarwal
2007-04-29  4:04 ` Port forwarding not working (nfcan: to exclusive) Jim Laurino
2007-04-29  4:56   ` neil
2007-04-29  7:10     ` Port forwarding not working (nfcan: to exclusive) " Jim Laurino
2007-04-29 13:06       ` Neil Aggarwal
2007-04-29 13:29         ` Jan Engelhardt
2007-04-29 14:39         ` Jim Laurino [this message]
2007-04-30  2:11           ` Port forwarding not working Neil Aggarwal
  -- strict thread matches above, loose matches on Subject: below --
2004-04-15 15:08 port " aksingh
2004-04-15 13:57 Nick Vazirianis
2004-04-15 14:07 ` Ray Leach
2004-04-15 14:28   ` Alexander Economou
2004-04-15 14:53     ` Antony Stone
2004-04-15 15:58       ` Cedric Blancher
2004-04-15 14:16 ` 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=1177857594l.3596l.2l@soapy \
    --to=nfcan.x.jimlaur@dfgh.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox