Activities

March 2008
M T W T F S S
    May »
 12
3456789
10111213141516
17181920212223
24252627282930
31  

SSH tunneling using putty

This is an example showing the ssh tunneling using putty application on windows. Our senarios is our mysql databae web interface access is limitted to certain ips eventhough we have ssh acccout on that sever.

All the SSH users can have get MySQL DB access and it’s more secure than a normal web access.

There are 2 ways to do this.

1. MySQL port forwarding using SSH
2, Apache port forwarding using SSH.

Note : Following steps are only applicable to windows users

Here I am prefer to use the second one using putty,

a, Download putty
b, Enter the username@hostname in the in IP address field. Refer. figure Step-1.jpg
c, Expand the tree named ‘SSH” and select the “Tunnels” from it. Then enter the value for source port (can able to change) to 8000 and destination field should be “localhost:80 “. Click add to save. Refer. figure Step-2 & 3
d, Click on open button to access the server and it will ask for storing host key information on the server. Click on the ” Yes” button and give password on prompt. Ref. figure 4
e, Now you have successfully connected to server with ssh tunneling is enabled on your local port (say 8000)
f, Now you can able to get secure access to the database through opening it http://localhost:8000/PhpMyAdmin/. Refer the figure 5

Step 1

Figure 1

Step 2
Tunneling

Step-3
save the cahes

Step 4
asking password

Step -5
Output window

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>