Linux Netfilter discussions
 help / color / mirror / Atom feed
From: "R D" <rkd@myrealbox.com>
To: netfilter@lists.netfilter.org
Subject: Port forwarding across two firewalls
Date: Mon, 10 May 2004 16:00:37 +0100	[thread overview]
Message-ID: <000301c4369f$8f8710b0$0f01020a@taita> (raw)


Hi all,

I sent this before but got no reply...is there nobody out there that can
help
 me!?

I have a static IP (10.2.1.15) on which I need to have both TCP and UDP
ports 5000 appearing to be external! The subnet I'm on has a
firewall(Debian) with an int IP 10.2.1.1 & ext 10.1.1.77 with gw 10.2.1.1
obviously. The second firewall/router is a US Robotics ADSL
Modem/Router with int IP 10.1.1.1 & ext 1.2.3.4.

When I lived in a house with just a Debian firewall and nothing configured
on the modem the following worked:

iptables -A FORWARD -p udp -d 10.2.1.15 --dport 5000 -j ACCEPT
iptables -A PREROUTING -t nat -p udp -d fw-ext --dport 5000 -j DNAT --to
10.2.1.15:5000

iptables -A FORWARD -p tcp -d 10.2.1.15 --dport 5000 -j ACCEPT
iptables -A PREROUTING -t nat -p tcp -d fw-ext --dport 5000 -j DNAT --to
10.2.1.15:5000

I've tried the same commands with fw-ext=10.1.1.77 and setting a 'port range
mapping' on the modem 10.1.1.77:5000-1.2.3.4:5000 for both UDP/TCP, but to
no avail!

Any gurus out there that can help/explain!?


Many thanks,
R



             reply	other threads:[~2004-05-10 15:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-10 15:00 R D [this message]
2004-05-11  8:33 ` Port forwarding across two firewalls Antony Stone
2004-05-17 17:44   ` Netfilter on BSD Saber Zrelli
2004-05-17 18:04     ` Antony Stone
  -- strict thread matches above, loose matches on Subject: below --
2004-05-06 20:36 Port forwarding across two firewalls R D

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='000301c4369f$8f8710b0$0f01020a@taita' \
    --to=rkd@myrealbox.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