[EDIT] Not my original post.
So my sister uses Ubuntu for all of her school work at her University several states away. She recently had a problem that I needed to log into her computer to fix. However, her school wouldn't allow me to connect to her computer but she could connect to mine. For ease of explanation I am going to call my system Debian (cause that is what I run).
The 2 Linux boxes are connected in such a manner.
Debian<---->Internet<---->Firewall<--->Ubuntu.
I have Zero-Zip-None control over the University Firewall.
At first I was trying a few different things and was getting a bit frustrated. So I made a post to ask for help and then I sat back in my chair hoping someone could help. About 20 seconds later it hit me like a ton of bricks*.
Now I am posting for anyone else who might find this handy in the future.
On the remote system (Ubuntu in this example) run:
- Code: Select all
ssh -R 1100:localhost:22 user@ubuntu.yourschool.org
Obviously change the user@ubuntu.yourschool.org to meet your needs. I have to add the port flag because my network requires I access it via port 443 (-p443).
Once established the local system (Debian) can then run:
- Code: Select all
ssh -p1100 user@localhost
Tada!! I have a SSH connection from the Debian box to the Ubuntu box!
I *heart* SSH
~S~
*So the example I found on Google recommended doing:
- Code: Select all
ssh -R 1100:localhost:1100
I don't know why, but it just didn't strike me as unusual. However, it kept failing. The reason why it kept failing is because I was trying to establish an SSH connection back to the original host on port 1100. SSH doesn't run on port 1100 (without modifications), it runs on port 22. Made that one (_1_!!) change and it all works now.