[OT] sshd reversed (?)

Hi all,
I'm looking for an idea, if of course there could be one. I've got a FreeBSD 8.2-RELEASE behind a firewall that allows ssh traffic go out but not in. Therefore from the outside world I cannot connect to the machine. I would like the machine to connect to me (i.e., to one of my external machines) a few times a day and give me control as for a normal SSH. Maybe netcat could help, but I don't know exactly how. Any idea?
 
Use SSH tunnel - connect to a machine on the outside that can accept SSH connections and then use that tunnel to access machines behind a firewall.

Your command is: ssh -f -N -R 12345:localhost:22 [email]user@someserver.com[/email] -p 22 But there are numerous tutorials for this all over the Internet.
 
Exactly. This is the classical situation a "reverse SSH tunnel" can be used in. (Search the 'net for those terms.)

After issuing the command (from your FreeBSD host) that Nightweaver mentioned, you can run (from someserver.com):
$ ssh fbsduser@localhost -p 12345

Note that sshd(8) must be running on both hosts.
 
Back
Top