So a while ago I set up a server on AWS, and used their generated SSH key. I saved the key to Lastpass, and have successfully retrieved it from there before, and got it working. However, after trying that again today, I can't get it to work.
-rw------- 1 itsgreg users 1674 Jun 6 12:51 key_name
I've tried ssh -i key_name
, ssh-keygen -f key_name
, but nothing works, I always get this error message:
Load key "key_name": invalid format
Is there any way to fix this?
Best Answer
Check the contents of
key_name
, if the agent saysinvalid format
, then there's something wrong with the key - like .. are you sure that's the correct key? Even if it's not the private key you need, the ssh agent won't returninvalid format
if the key is working, you simply won't be able to connect. You might have placed your public key in there, for some reason. Check it!