Using VNC Tunneling over SSH - page 3
Suppose I want to show the remote desktop user how I use an application on my laptop. He's still behind that firewall (with the SSH port routed to his desktop Linux machine) and I have a software firewall running on my machine. My firewall blocks all inbound ports.
In this case, everything sort of just works in reverse.
Again, the x11vnc server needs to be started. This time, it's on my laptop.I can again initiate the tunnel from my end, this time using the -R option. R stands for remote.
laptop> ssh xx.xxx.x.xx -o Compression=yes -o CompressionLevel=1 -R 5900:localhost:5900
Now, all the desktop user has to do is start up his vncviewer to watch what I'm doing on my laptop.
desktop> vncviewer localhost:0
Then, magically, whatever appears on my laptop screen also shows up in a window on the user's desktop.
When the educational/VNC session is completed, don't forget to re-configure the firewall rules to again block the SSH port.