35
9
I have a public/private key pair. Neither of them have any sort of passphrase associated with them.
Whenever I try to ssh using either the private or public(and I'm pretty sure I should only be using the public key), I get queried for a passphrase, and then of course can't connect up.
Anyone have any idea how to get around this? Am I typing some command incorretly? I am trying to ssh into a server that I have setup in my ~/.ssh/config file(correctly, since this exact same setup works on another server) with the key stored in ~/.ec2/key.ppk
I've also tried using puttygen.exe to generate a new private key WITH a passphrase, and then using that key, and when I type the passphrase, it still fails.
This error also is given if the file is in correct format - so double and triple check you copied and pasted properly if manually creating it. – Daniel Sokolowski – 2015-09-03T19:40:27.187
Correct, this is a key generated by puttygen from a key that works in putty. When I putty into the same server(from the machine that hosts the cygwin instance) it works fine with the exact same key. When i try to connect via ssh from cygwin, it bombs out. I'm confused how to make this work. – llaskin – 2010-06-25T13:38:49.503
Is
ssh-rsa AAAAB3NzaC1y...... etc
is the format from openssh, right? I have this format in my private key. The header states:PuTTY-User-Key-File-2: ssh-rsa Encryption: none Comment: imported-openssh-key Public-Lines: 6
But the file is stored as a id_rsa file. Does this mean that this is still in .ppk format, even though the name of the file is justid_rsa
– alpha_989 – 2018-01-15T14:59:46.807Found out the answer for the different formats here. In my case even though the extension of the file didnt have
– alpha_989 – 2018-01-15T16:12:39.477.ppk
, it still was in putty format, which confused me, as it was showing all kinds of errors, but not giving me any direct hint that the problem was with the format of the key: https://stackoverflow.com/a/44391850/47528836I think mrverrall's points is that the file format for the PuTTY private key is not the same as the file format used for OpenSSH (the ssh client in cygwin). So OpenSSH is just failing to use the private key data because it can't figure out what the data means. But PuTTY has an "export" option, so you can get data in the "PEM" format needed. – Phil P – 2011-01-23T21:44:14.440