microsoft / Git-Credential-Manager-for-Windows

Secure Git credential storage for Windows with support for Visual Studio Team Services, GitHub, and Bitbucket multi-factor authentication.
Other
2.87k stars 591 forks source link

Issues authenticating to GitHub? #917

Open mjcheetham opened 4 years ago

mjcheetham commented 4 years ago

GitHub will disable password-based authentication on APIs Git Credential Manager for Windows uses to create tokens. As a result, GCM for Windows will no longer be able to create new access tokens for GitHub.

Brownouts are planned during October 2020 before the final removal of the password-based APIs in November 2020.

During these brownouts you will be unable to use GCM for Windows to create new tokens during clone/fetch/push.

How to fix

Git Credential Manager Core (GCM Core) supports OAuth-based authentication with GitHub and is the replacement for GCM for Windows.

Please update to Git for Windows 2.29 and make sure "Git Credential Manager Core" is selected in the installer when asked to "select a credential helper", or manually install GCM Core from here.

Unable to upgrade to Git for Windows 2.29 or GCM Core?

If you are unable to upgrade to Git for Windows 2.29 onwards, or use GCM Core, please follow the below workaround:

  1. Go to https://github.com/settings/tokens/new to create a new personal access token (PAT)

  2. Enter a name ("note") for the token and select the repo, gist, and workflow scopes: image ... image ... image ... image

  3. Click "Generate Token"

image

  1. [IMPORTANT] Keep the resulting page open as this contains your new token - this will only be displayed once!

image

  1. Open a command prompt (cmd.exe) and type the following:

    cmdkey /generic:git:https://github.com /user:PersonalAccessToken /pass
  2. You will prompted to enter a password – copy the newly generated PAT in step 4 and paste it here, and press Enter

image


Update: Git for Windows 2.29 is now available with GCM Core as default.