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

Support Git Credential Helpers #18654

Closed
deanward81 opened this issue May 20, 2024 · 3 comments · Fixed by #18700
Closed

Support Git Credential Helpers #18654

deanward81 opened this issue May 20, 2024 · 3 comments · Fixed by #18700

Comments

@deanward81
Copy link

The feature request

My organization has started severely restricting the lifetime of PATs issued from Azure DevOps. Unfortuantely, that means I have to go generate a new PAT and enter the details into GitHub Desktop every 7 days. When using git from the CLI I have it configured to use the Git Credential Manager to allow me to use OAuth to authenticate to DevOps.

Proposed solution

Use the configured Git credential helper instead of popping up a username/password dialog to authenticate to services that support OAuth.

Additional context

This has been asked about before here- some services cannot be authenticated to with just a username and password - they need the additional context provided by the configured credential helper.

I tried configuring the bundled git to use the Git Credential Manager from the CLI and it works correctly. When I tried to use it from the UI it still pops the username and password dialog. I also tried symlinking git.exe to my correctly configured system git, but it doesn't work from the UI either.

@niik
Copy link
Member

niik commented May 29, 2024

Hi @deanward81, thanks for reaching out. We've heard reports of restricted PAT lifetimes on Azure Devops and I wanted to get you a little update here. I've opened #18700 which adds experimental support specifically for Git Credential Manager (GCM). Note that this isn't generic credential helper support as your title suggests but reading your issue it seems that for you at least the specific need is for GCM.

It's still pending review but assuming all goes well we intend to ship this feature to our beta channel to gather feedback. Hopefully you'll be able to help us test this once that lands on beta.

@niik
Copy link
Member

niik commented Jun 12, 2024

Hey @deanward81, we just shipped GitHub Desktop 3.4.2-beta2 to our beta channel. This includes support for using Git Credential Manager. It's currently off by default but you can enable it in Settings under the advanced tab. We believe this will address the authentication problems outlined in this issue.

Screenshot of Desktop's advanced preferences section with a highlight around the new option to enable Git Credential Manager

When Git Credential Manager (GCM) is enabled all credentials for third-party (i.e. Azure Devops, BitBucket, GitLab etc) will be handled, and stored, outside of GitHub Desktop. GCM supports browser-sign in to many popular services and will avoid the need to create personal access tokens (PATs).

Please download our beta version from https://desktop.github.com/beta/ to give this a go and please report back with your experience. We'll be collecting feedback in our beta channel which will inform when we make this available to all users. Installing the beta version will not clear your preferences or tracked repositories and you can switch to the production version by simply downloading the latest version from https://desktop.github.com.

@deanward81
Copy link
Author

@niik amazing, thank you so much, downloading it now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants