Saturday, July 25, 2015

[SSH] Configure SSH Key-Based Authentication (windows as client , linux as server) - part2

This article continue with this post:
[SSH] Configure SSH Key-Based Authentication (windows as client , linux as server) - part1

Step 7


Download PuTTY from this page and open it:
http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html

Step8

Input your hostname or ip address and check open.


Step 9

Follow the instruction input your username and password to login in puTTY command promt.

Step 10

Use this command to create a .ssh directory with a blank authorized_keys file in your home directory on your server, and also set the access permissions.

mkdir ~/.ssh; touch ~/.ssh/authorized_keys; chmod 700 ~/.ssh

Step 11

Use this command for opening the file you just created to edit.
nano ~/.ssh/authorized_keys

Step 12

Paste the Public key for OpenSSH authorized_keys you marked in step5 (if can't edit, press i to enter insert mode), paste it and save.


Step 13

Type "logout" to end your session.
logout

Step 14

Select "SSH"->"Auth" in category and then browse the private key generated at step 6  , click open.

Step 15

Select "session" at category, input your ip address or hostname shown at the image:

Step 16

Follow the instruction to enter your login username, and then it would ask for your "passphrase", you should enter the passphrase you set at Step5


If your passphrase is correct, you can enter the server by SSH Key-Based Authentication successfully

No comments :

Post a Comment