Puttygen key format
How to use SSH Public Key with PuTTY to connect to a Linux machine
You have to follow these properly.Configure the Public Key in SSH ServerCopy the public key in to SSH Server via SFTPput publicy_key
Login to SSH server verify the copied public keyls -l public_key
Since the public key does not have any permissions, change it to 400 (for read)chmod 400 public_key
Use ssh-keygen tool to create openSSH format public keyssh-keygen -if public_key > public_key_openssh_format
Add the created openSSH public key to authorized_keys filescat public_key_openssh_format > ~/.ssh/authorized_keys
Check the permissions of .ssh folder and authorized_keys file for access permissionsls -al ~/.ssh
Verify the Key Pairs with PuTTYNow, the key based authentication can be verified with PuTTY.
Enter the host name and portConfirm the Security alertIf you are still stuck. Then you have to re-create the user and follow the steps and configure the public key again.The user can be recreated using the following command: