Table of Contents

SSH Portfoward



Local Foward

RemoteDesktop 1

+----------------+     +-------------+      +---------------+
| PC             |---> |SSH Server   | ---> |Target Server  |
|  192.168.100.2 |     | 192.168.0.5 |      |  192.168.0.10 |
|    Port 3388   |     |             |      |   Port 3389   |
+----------------+     +-------------+      +---------------+
  1. PC # ssh -L 3388:192.168.10:3389
  2. PC # mstsc /v:127.0.0.1:3388


RemoteDesktop 2

+----------------+     +-------------+      +---------------+
| PC             |---> |SSH Server   | ---> |Target Server  |
|  192.168.100.2 |     | 192.168.0.5 |      |  192.168.0.10 |
|                |     |  Port 3388  |      |   Port 3389   |
+----------------+     +-------------+      +---------------+
  1. SSH Server # ssh -L 3388:192.168.10:3389
  2. PC > mstsc /v:192.168.0.5:3388


Dynamic Foward

+----------------+     +-------------+      +---------------+
| PC             |---> |SSH Server   | ---> |Target Server  |
|  192.168.100.2 |     | 192.168.0.5 |      |               |
|   port 10000   |     |             |      |               |
+----------------+     +-------------+      +---------------+
PC 
# ssh -D 10000 user@192.168.0.5
# http_proxy=socks5://127.0.0.1:40000 yum install <package_name>