Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SSH key git authentication #16542

Open
halldk opened this issue Apr 16, 2023 · 2 comments
Open

SSH key git authentication #16542

halldk opened this issue Apr 16, 2023 · 2 comments
Labels
bug Confirmed bugs or reports that are very likely to be bugs priority-2 Bug that affects more than a few users in a meaningful way but doesn't prevent core functions

Comments

@halldk
Copy link

halldk commented Apr 16, 2023

The problem

When setting GitHub desktop to use SSH key for git authentication, if the key has a passphrase that is not currently unlocked in the ssh-agent, it sits there and infinitely "fetches" data, with no prompt for the ssh key passphrase, and there is no timeout.

Release version

3.2.1

Operating system

Windows 11

Steps to reproduce the behavior

~.ssh\config:

Host github.com
    HostName github.com
    IdentityFile "~/.ssh/key_rsa"
    User git

GitHub repos downloaded with ssh key previously
Attempt to fetch repository that you've downloaded with the key.

To see it working:

~.ssh\config:

Host github.com
    HostName github.com
    IdentityFile "~/.ssh/key_rsa"
    User git

Using powershell:

# If ssh agent is not setup:
Get-Service ssh-agent | Set-Service -StartupType Automatic
# Setting to automatic doesn't start it, to start it without rebooting the first time:
Start-Service ssh-agent
# If not already loaded into agent:
ssh-add ~\.ssh\key_rsa
# You'll be prompted to enter the passphrase for the key, at which point it will tell you if the phrase was correct and if it was added to the agent

Log files

2023-04-16.desktop.production.log

Screenshots

image

Additional context

No response

@steveward
Copy link
Member

Thanks for reporting this @halldk, I'll take a look and see if I can reproduce this on my Windows machine.

@steveward steveward self-assigned this Apr 19, 2023
@steveward
Copy link
Member

I was able to reproduce this @halldk -- fetching and cloning both were hanging when using SSH with a passphrase on Windows. However, when I went to File > Options > Advanced and deselected the option to use the system OpenSSH things started working again. Could you test that to see if it gets things working for you? I'll mark this as a bug for us to investigate.

@steveward steveward added bug Confirmed bugs or reports that are very likely to be bugs priority-2 Bug that affects more than a few users in a meaningful way but doesn't prevent core functions labels Apr 20, 2023
@steveward steveward removed their assignment Apr 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Confirmed bugs or reports that are very likely to be bugs priority-2 Bug that affects more than a few users in a meaningful way but doesn't prevent core functions
Projects
None yet
Development

No branches or pull requests

2 participants