Date: Mon, 19 Nov 2001 19:33:28 -0500 From: Chris Ptacek <cptacek@sitaranetworks.com> To: "'freebsd-questions@freebsd.org'" <freebsd-questions@freebsd.org> Subject: SSH forwarding questions. Message-ID: <31269226357BD211979E00A0C9866DAB02BB974C@rios.sitaranetworks.com>
next in thread | raw e-mail | index | archive | help
What I am trying to do is setup forwarding of a port (5907) from the remote machine (server) to my local machine (client) using a different port (5901). The setup looks a little like this: Client NAT/Firewall +---+ +---+ | 1 |----| 2 |---> Internet +---+ +---+ +---+ +---+ Internet -->| 3 |----| 4 | +---+ +---+ Server/NAT Remote machine behind NAT I would like to connect (with SSH) from machine 1 to machine 3 and setup remote forwarding of the port. When machine 4 tries to connect to the given port on machine 3 it is forwarded to machine 1. The command I am trying is as follows: ssh -C -l<username> -R 5907:localhost:5901 <IP of machine 3> Machine 1 is running FreeBSD 3.1 Machine 3 is running FreeBSD 4.4 I can make the ssh connection between Machine 1 and Machine 3, but it doesn't seem to be forwarding the ports. Some other tests I did: On a FreeBSD 3.1 machine on the same subnet as Machine 1 I tried the above command. I was able to successfully forward the port and connect. On a FreeBSD 4.3 machine on the same subnet as Machine 1 I tried the above command. I was not able to successfully forward the port and connect. I am guessing that this may not be a NAT issue since I also seem to be having troubles with the 4.3 box on the local subnet. The difference is that a netstat -na shows the listening on 5907 on the 4.3 box (can't connect though) while a netstat -na doesn't show anything listening on 5907 on machine 3. Any information on how to solve this problem would be greatly appreciated. Is this a configuration problem, a NAT issue, or both? Thanks, Chris To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?31269226357BD211979E00A0C9866DAB02BB974C>