...from my Mac. I think Keychain Access remembers my passphrase and applies it every time I log in to a server, but in this instance I can't log in to the remote server directly from my laptop; I have to first log in to a different server and then attempt to ssh to my target. Which doesn't work because even though I have copied my id_rsa to my user dir on the first server and set permissions correctly, it is not automatically decrypted as it is on my laptop and I am prompted for a passphrase. Which I don't know. So my question is: is there a way to retrieve that passphrase from Keychain Access? Or am I hosed?


[I]s there a way to retrieve that passphrase from Keychain Access? Or am I hosed?

Keychain Access has to store the passphrase to be able to use it. So even without knowing the application, the answer has to be yes (to the former, not the latter), although it could be difficult to retrieve it.

In you specific case, it's easy. Just open Keychain Access, search for the entry regarding your key file in Keychains and toggle the box Show password.

| improve this answer | |

Sorry, you are hosed....

the point of having a passphrase is to protect the key for unauthorized use. Having it be easily or even designing it to be crackable would ruin the trust anybody had and nobody would be using a passphrase.

You'll have to generate a new public/private key and optional passphrase....

| improve this answer | |
  • -1. Given the answer by Dennis that Shows how to do it. In this particular case the passphrase is easily accessible. – TomTom Dec 24 '12 at 6:36
  • 1
    Although I might agree that I might have misunderstood something in the question and based on that I provided the wrong answer....I don't think I deserve the language or tone that you provided here in your comment. Apparently from the comments, others interpreted the question the same way that I did. – mdpc Dec 24 '12 at 6:45
  • 1
    NOTE: Offensive comment has been edited out, since my my last comment. – mdpc Dec 24 '12 at 6:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy