当前位置:   article > 正文

Support for password authentication was removed on August 13, 2021

support for password authentication was removed on august 13, 2021

Support for password authentication was removed on August 13, 2021

环境: 2021年08月15日, git version 2.30.1 (Apple Git-130), macOS Big Sur 11.4

Overview 问题概览

8月13号后, git pull & git push均报错

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/HouShiqi/SQIWritings.git/': The requested URL returned error: 403
  • 1
  • 2
  • 3

Reason 问题起因

2021 年 8 月 13 日官方移除了对密码身份验证的支持, 原来通过https, 账号密码方式访问 github 仓库已经不被支持, 若还想使用https访问, 需要改用个人访问令牌(用此令牌代替原来的密码)。

Solution 解决方式

  1. 删除钥匙串中存储的 github 互联网密码, 这样再次使用git pull等命令, shell 会提示输入新的账号密码, 而不再使用钥匙串中存储的旧密码.

  2. 打开github.com官网, 点击头像下拉菜单 -> Settings -> Developer Settings -> Personal access tokens -> Generate new token;

  3. 填写如下必要信息, 勾选 token 的权限范围;
    在这里插入图片描述

  4. 点击底部Generate token按钮生成 token, 代替原来的密码使用即可;

Personal access token 是什么 ?

Personal access tokens function like ordinary OAuth access tokens. They can be used instead of a password for Git over HTTPS, or can be used to authenticate to the API over Basic Authentication.

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/黑客灵魂/article/detail/741942
推荐阅读
相关标签
  

闽ICP备14008679号