forward all connections to my localhost:8080 to port 80 on remote.host
# ssh -L 8080:localhost:80 firstname.lastname@example.org
forward all connections to my localhost:8080 to port 80 on the router gateway of another network.
very handy for remotely gaining access to boxes (eg: adsl router configs) that do not have remote access setup by default.
# ssh -L 8080:192.168.0.1:80 email@example.com
forward all connections that connect to the remote box on port 80 through to my local box on port 8080.
could be used to give someone on a remote network secure access to a service on your local network.
eg: without setting up port forwarding in your router anywhere.
# ssh -R 80:localhost:8080 firstname.lastname@example.org
872 total views, 1 views today