4
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

GitHub Error "Support for password authentication was removed. Please use a personal access token instead." for windows

Last updated at Posted at 2021-08-15

パスワード認証の有効期限が2021年8月23日までらしく、アクセストークンを利用したログイン方法に変更する必要があるとのこと。

エラー内容

PS C:\XXXXXXXX/XXXXXXXX/XXXXXXXX/XXXXXXXX.git/> git push
Logon failed, use ctrl+c to cancel basic credential prompt.
remote: Support for password authentication was removed on August 13, 2021. Please use a personal access token instead.
remote: Please see https://github.blog/2020-12-15-token-authentication-requirements-for-git-operations/ for more information.
fatal: unable to access 'https://github.com/XXXXXXXX/XXXXXXXX.git/': The requested URL returned error: 403

結果

以下を実施することで、いつも通りに利用できるようになりました。

  • githubで二段階認証のを設定。
  • githubでアクセストークン(repo権限)を発行。
  • Windows資格情報のパスワードをアクセストークンに変更。

実施内容の詳細

二段階認証の有効化

エラーログのURLを確認し、二段階認証を有効化しました。

github blog

スマホの認証アプリはgoogle 認証システムを利用しました。

Go to setting from github => Account security => Two-factor authentication => Enable

アクセストークンの発行

有効期限は無期限も設定できるようです。

Go to setting from github => Developer settings => Personal access tokens => Generate new token

image.png

アクセストークンはこちら

image.png

windows認証情報の修正

Go to Credential Manager from Control Panel => Windows Credentials => find git:https://github.com => Edit => On Password replace with with your Github Personal Access Taken => You are Done

image.png

image.png

image.png

image.png

パスワードgithubで発行したアクセストークンを設定する。

image.png

以上です。

4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?