I generated an OpenSSH private key using puttygen (and exported it in OpenSSH format). How can I put a password on this existing key (I know how to generate a new key with a password)?
Thanks!
I generated an OpenSSH private key using puttygen (and exported it in OpenSSH format). How can I put a password on this existing key (I know how to generate a new key with a password)?
Thanks!
Try the command ssh-keygen -p -f keyfile
From the ssh-keygen man page
-p Requests changing the passphrase of a private key file instead of
creating a new private key. The program will prompt for the file
containing the private key, for the old passphrase, and twice for
the new passphrase.
Use the -p option to ssh-keygen. This allows you to change the password rather than generate a new key.