It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Sourcetree dont ask me for ssh-keygen passwords, when i create and add a second key

First i create a ssh-key with this tutorial for bitbucket:

https://confluence.atlassian.com/bitbucket/set-up-an-ssh-key-728138079.html#SetupanSSHkey-ssh1

Everything works fine. When i restart sourcetree, a window opend and ask me for the ssh-key password. After entering i can push and pull.

For another git-Server i need a second key. For this i used this tutorial:

https://confluence.atlassian.com/bitbucket/set-up-additional-ssh-keys-271943168.html#SetupadditionalSSHkeys-ssh1

After adding the key, i would asked for the password for my this new key.

In this working-session everything works fine.

After closing and restart sourcetree, the password-prompt-window does not opened, so i could not enter the passwords and after this i could not push and pull. The git-servers told me, Permission denied (publickey). fatal: Could not read from remote repository. Thats right, because both accounts needs my passwords.

Only when i add both keys again via bash, then i would asked for both passwords and i can work again during the next restart.

I know theres a option to add keys to sourcetree (Tools > Add SShkey). I see that sourcetree add the keys to a semicolon seperated list (Tools > Options > SSH Keys), and the list would be longer and longer with the same keys, but it doesnt matter, they dont ask me again for the passwords.

It would be correct if I have in the semicolon seperated list only two entries and i would asked for both passwords again when i starting Sourcetree.

Can you help me?

 

2 answers

0 votes
Manju Atlassian Team Dec 22, 2017

Please check if your keys are added to ssh-agent on macOS. Run below command in a terminal window to check the list,

ssh-add -l

If you don't find your keys listed, please add them to the agent using below command

ssh-add <path_to_key>

for example,

ssh-add ~/.ssh/id_rsa

This would ensure you don't have to worry about entering password when using Sourcetree.

Hope this helps.

 

Thanks,
Manjunath
Sourcetree Mac Developer

Dear Manjunath,

i work on a windows machine. I open the bash with sourcetrees commandline-Button.

Before i can enter your commands, i must enter

eval $(ssh-agent -s)

without this command, ive got only the note:

Could not open a connection to your authentication agent.

After i´ve enter my and your commands, i could not pull and push.

In the Moment i do following: I go to Tools > Options > SSH-Keys and delete the entries. After this, i go to Tools >  Add SSH-key, connect to the first key and Sourcetree ask me in a Commandline-Window the password. The same procedure with the second Key-File. For this working session everything is fine. But when i close Sourcetree, Sourcetree forgets everything.

Can you understand that?

 

Regards, Mario

Manju Atlassian Team Dec 23, 2017

My bad! 

Dont know why I assumed it was on Mac. I’ll have our windows team respond to it. Sorry for the confusion. 

I changed the question-tags from macos to windows ... hope that help for assign to the windows team ...

Hi
That looks like a bug you've found when supporting multiple keys in openssh, please follow:
https://jira.atlassian.com/browse/SRCTREEWIN-8315

Hi

the link is a mistake. I saw that you´ve create a bug-report:

https://jira.atlassian.com/browse/SRCTREEWIN-8315

I checked Jira if another ticket is opend and i found the follow:

https://jira.atlassian.com/browse/SRCTREEWIN-4043

The discriped solution with the double-quotes works for me. When i start sourcetree, i would asked for the passwords of the both keys. This is what i aspected.

You can couple the tickets 8315 with 4043 and i would follow 4043 ...

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Sourcetree

Sourcetree for Windows - CVE-2019-11582 - Remote Code Execution vulnerability

A vulnerability has been published today in regards to Sourcetree for Windows.  The goal of this article is to give you a summary of information we have gathered from Atlassian Community as a st...

4,917 views 0 12
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you