Posts

Showing posts from May, 2018

SSH Tunneling or SSH Port forwarding

Image
One of the tricky topic is SSH port forwarding. There are many tutorials about this but they are quite complicated for students or junior level engineers to understand. Here I will try to explain those concepts using scenario so that it can be easily grasped.  Scenario: Your office firewall blocks access to facebook.com URL. Your laptop at home can access facebook.com easily. Your office environment/firewall allows SSH connection to your home laptop. Goal: Make office PC access facebook.com without performing any changes to office firewall. Description: In order to achieve this your home laptop needs to run SSH server. What we need to do in this case is to create a SSH tunnel from Office PC to Home Laptop and do some port forwarding.  In above figure you can see that if we can create tunnel between office and home machines. Just a SSH tunnel won’t allow us to access facebook.com from office PC. We need port forwarding here. In order to achie