Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Load multiple password-protected OpenSSH keys

FrancescoP November 21, 2014

I have 2 SSH keys I need to load when starting SourceTree, which are password-protected.

Since I am on Windows and can't use Pageant (due to its lack of support to OpenSSH keys) I have to use OpenSSH, but it doesn't properly work:

  • if there is just one key added into SourceTree, a command line pops up asking me for the password (and it works)
  • if I add a second key through SourceTree (Tools -> Add SSH key), it asks me for the password (and it works)
  • if I close SourceTree and open it up again, a command line pops up and then immediately closes itself, thus failing to load both of my SSH keys

Is there a way to solve this? The only workaround is to re-add the SSH key I need just before fetching/pushing, if I remember I previously closed SourceTree or rebooted my PC.

1 answer

0 votes
Seth
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 21, 2014

You can use the putty key generator to convert OpenSSH private keys to the format pageant prefers. They should still work fine with the openssh public keys.

FrancescoP November 21, 2014

I really don't want to keep multiple copies of my keys, isn't there another solution?

Seth
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 22, 2014

Do you use the private keys for something that requires the openssh format? The conversion can work both ways, so you could merely keep the ppk format for your private keys, and convert your public keys to openssh or putty's public keys as necessary. I generate all my keys with puttygen, and invariably have to convert my public keys to openssh for installation on linux servers.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events