Bridging tunnels

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
So I'm at a college, but have a shell account at a sever out in the
world somewhere. I cannot VNC into my dorm from the outside world
because of the evil firewall between my dorm and any incoming
connections, so I've come up with a solution:  Create a permanent
tunnel from my dorm to a shell account, and then set up the shell
account so that when I create a new tunnel to it, it automatically
links the two tunnels so that it would look like i was connected
directly to my computer in my dorm. Beautiful in theory, but I'm not
sure how to set up the shell account part of the deal. I figure I need
to set it so that the incoming ssh port on one tunnel is dumped
straight to the outgoing ssh port of the other tunnel.  But I'm not
sure how to do this, can someone help and/or give advice on the
situation at large.  Thanks =)

Re: Bridging tunnels

What does "shell account" mean ?
- Can you ssh to it ?
- Does it allow port forwarding ?

If so, you could forward your VNC-server's VNC-port to your "internet
computer" INETGW. There you could connect from anywhere and attach to
the forwarded port.

On your VNC-server (asuming you are using port 5800)

ssh -R 5800: INETGW -Nf
-> simply open port 5800 on INTEGW and forward it to your localhost
port 5800.
-> -Nf simply doesn't create a remote shell, only the port will be
forwarded. You will not have a shell on INETGW.

Now from any computer:

ssh -L 5800: INETGW -Nf

-> this forwards the remote port on INETGW (which in fact is the
forwarded port from your VNC-server) to your "any computer".

Now on your "any computer":

vnc localhost
-> this would connect you to your VNC-server via the INETGW.

Best regards,

Site Timeline