Ethical Hacking

Learn to find vulnerabilities before the bad guys do! Gain real world hands on hacking experience in our state of the art hacking lab. Course designed and taught by expert instructors with years of penetration testing experience. 12 student maximum in every class. Certification attempt included in every package.
Computer Forensics Training at InfoSec Institute

Gain the in-demand skills of a certified computer examiner, learn to recover trace data left behind by fraud, theft, and cybercrime perpetrators. Discover the source of computer crime and abuse at your organization so that it never happens again. All of our class sizes are guaranteed to be 12 students or less to facilitate one-on-one interaction with one of our expert instructors.




Network Security Secure-Shell
[Top] [All Lists]

Re: IP checking of hosts on a forwarded private network

Subject: Re: IP checking of hosts on a forwarded private network
Date: Fri, 29 Jun 2007 17:45:07 -0700 (PDT)
On Fri, 29 Jun 2007, David Liontooth wrote:


On a Debian network, I've set up iptables forwarding into a private 
network, using this sort of thing:

iptables -t nat -A PREROUTING -p tcp -d 163.57.143.178 --dport 9000 -j 
DNAT --to 192.168.0.1:22

The three machines on the private network each get assigned their own 
port on the gateway:

ssh 163.57.143.178 -p 9001

gets me to the elusive 192.168.0.2 and so on. This works great, except for
openssh's host ip checking. As far as openssh is concerned, all four
machines are the same machine, with four different RSA keys.

On SSH2, known_hosts stores host:port. Is something equivalent available 
in openssh? Workarounds?

Never mind, I found the answer in the archives --

Host port22
     HostName 1.2.3.4
     Port 22
     HostKeyAlias port22
Host port2022
     HostName 1.2.3.4
     Port 2022
     HostKeyAlias port2022

Works!

Dave

<Prev in Thread] Current Thread [Next in Thread>