I set up a Reverse SSH tunnel from my home computer to my work server:
ssh -f -N -R 19999:localhost:22 remoteuser@server
To connect to my home computer I have to first log in to the server and then from there log in to my home computer:
otheruser@othermachine$ ssh remoteuser@server
remoteuser@server$ ssh -p 19999 homeuser@localhost
But I want to be able to skip one step and connect directly through port 19999, something like:
otheruser@othermachine$ ssh -p 19999 homeuser@server
I'm not that familiar with iptables
and I'm have been reading but it seems so confusing just to open a port. I'm pretty sure that I need to add a rule to iptables
, but is there anything else that I need to do?
The server is RHEL 6 and my home computer is Ubuntu 14.04