I have a public key in the format:
---- BEGIN SSH2 PUBLIC KEY ----
Comment: "somename-20060227"
AAAAB3NzaC1yc2EAAAABJQAAAIBmhLUTJiP[and so on]==
---- END SSH2 PUBLIC KEY ----
Usually I see keys in the format like this:
ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAqof[and so on]
Can I just copy the first key in the authorized_keys file or do I have to modify it somehow so it looks like the second one? I think the first one was generated by PUTTYgen while the second one was generated by ssh-keygen.
Best Answer
use
ssh-keygen -i
to convert SSH2-compatible format to OpenSSH compatible format.from
man ssh-keygen
: