Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Richard Plana <rplana@zicorp.com>
To: netfilter@lists.netfilter.org
Subject: Adding listening ports
Date: Tue, 29 Jul 2003 13:06:59 -0600	[thread overview]
Message-ID: <3F26C5D3.7080002@zicorp.com> (raw)

Hi,

Because of (overly?) strict security policies at our company, one can 
only make TCP connections to ports 80 and 443. I was wondering if 
netfilter could be used to redirect packets destined for port 443 to the 
listening sshd daemon on port 22 on an external machine.

I tried "iptables -I RH-Lokkit-0-50-INPUT 5 -p tcp -m tcp --dport 443  
--syn -j ACCEPT" (I'm using RedHat's default config) and "iptables -t 
nat -A PREROUTING -p tcp --dport 443 -j DNAT --to-destination 
127.0.0.1:22" to do the actual routing, but that didn't seem to work:

$ ssh -p 443 localhost
ssh: connect to host localhost port 443: Connection refused

Suggestions would be appreciated.
-- 


*Richard Neal Plana, B.Sc., CCNA*
Lead Software Engineer
Zi Corp.



             reply	other threads:[~2003-07-29 19:06 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-29 19:06 Richard Plana [this message]
2003-07-29 21:06 ` Adding listening ports Sebastian
  -- strict thread matches above, loose matches on Subject: below --
2003-07-29 20:16 Daniel Chemko

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=3F26C5D3.7080002@zicorp.com \
    --to=rplana@zicorp.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