TFS(Visual Studio Team Services) git认证失败 authentication fails 的解决方案
问题描述
TFS 的git仓储地址使用http协议时,在visual studio中使用正常,可是git pull运行失败,提示 authentication fails。
初步判断原因为默认的 credential.helper 与 TFS 不兼容导致。
TFS 2015 与 Azure Devops(TFS 2019)都有这个问题。TFS2019建议使用ssh认证方式绕过这个问题,这样也更加安全。
解决方法
使用管理员身份运行 git-bash / cmd / powershell 执行以下指令
git config --system credential.helper wincred
再次执行git pull,依照提示输入正确的账号密码即可。
管理凭证可打开:windows控制面板-用户账户-凭据管理器-Windows凭据-普通凭据。如果存储的凭据有误,可修改或删除错误的凭据。
进阶配置详解
有关credential helper for windows的详细内容:https://github.com/Microsoft/Git-Credential-Manager-for-Windows
git使用credential.helper来存储凭证。默认为manager(system级别)。在安装git时,会默认安装 credential.helper。
查看系统支持的credential.helper
git help -a | grep credential-
查看已保存的相关设置
git config --global -l | grep credential.helper
git config --system -l | grep credential.helper
去除credential.helper 设置,system级别需要管理员权限,system级别的配置会覆盖global级别的设置。
git config --system --unset credential.helper
git config --global --unset credential.helper
清除保存的凭证 https://stackoverflow.com/questions/15381198/remove-credentials-from-git
git credential-manager clear
Linux系统环境,可设置credential.helper为store
使用store会将密码明文存储,查看或修改已存储的密码可编辑配置文件 ~\.git-credentials
TFS(Visual Studio Team Services) git认证失败 authentication fails 的解决方案的更多相关文章
- Visual Studio Team Services使用教程【6】:Readers tfs组checkin权限修改
你也可以只开启部分代码的权限 把上面开启的整个应用的权限先去掉 只开启一个文件的权限 2017.4.23之后建议朋友看下面的帖子 TFS2017 & VSTS 实战(繁体中文视频) Visua ...
- Visual Studio Team Services使用教程【5】:Readers tfs组成员添加
2017.4.23之后建议朋友看下面的帖子 TFS2017 & VSTS 实战(繁体中文视频) Visual Studio Team Services(VSTS)与敏捷开发ALM实战关键报告( ...
- 使用Visual Studio Team Services持续集成(四)——使用构建运行测试
使用Visual Studio Team Services持续集成(四)--使用构建运行测试 使用构建来运行测试来验证集成是一个很好的实践. MyHealth.API.IntegrationTests ...
- 使用Visual Studio Team Services持续集成(一)——构建ASP.NET Core
使用Visual Studio Team Services持续集成(一)--构建ASP.NET Core 概述 持续集成(CI)是将代码尽可能频繁地集成到共享仓库中的过程.在代码集成期间,构建中断或测 ...
- 使用Visual Studio Team Services进行压力和性能测试(二)——压力测试执行
使用Visual Studio Team Services进行压力和性能测试(二)--压力测试执行 1.点击Run test将会该压力测试进行排队,我们将看到等待测试代理屏幕.Visual Studi ...
- Visual Studio Team Services持续集成到Github仓库
Devops如何用VSTS持续集成到Github仓库! 工欲善其事,必先利其器.在开始正式的教程之前我们先来聊聊准备工作. 管理工具会VSTS. 代码管理会用GITHUB. 服务器会用Azure. ...
- 每次打开VS都报错:我们无法自动填充你的 Visual Studio Team Services 帐户
我们无法自动填充你的 Visual Studio Team Services 帐户.遇到下面的错误: TF400813: Resource not available for anonymous ac ...
- 使用Visual Studio Team Services进行压力和性能测试(一)——创建基础的URL压力测试
使用Visual Studio Team Services进行压力和性能测试(一)--创建基础的URL压力测试 概述 压力测试使应用程序更加健壮,并审核在用户负载下的行为,这样我们可以在当前的基础设施 ...
- 使用Visual Studio Team Services持续集成(三)——使用工件
使用Visual Studio Team Services持续集成(三)--使用工件 工件是应用程序的可部署组件.Visual Studio Team Services有能力在构建过程中显式地管理工件 ...
随机推荐
- GOF23设计模式之访问者模式(visitor)
一.访问者模式概述 (1)模式动机 对于存储在一个集合中的对象,他们可能具有不同的类型(即使有一个公共的接口),对于该集合中的对象,可以接受一类称为访问者的对象来访问,不同的访问者其访问方式也有所 ...
- 20165226 实验三 敏捷开发与XP实践
实验三 敏捷开发与XP实践 实验目的 一.安装alibaba 插件,解决代码中的规范问题.在IDEA中使用工具(Code->Reformate Code)格式化代码,研究一下Code菜单,比较功 ...
- 【学步者日记】实现破碎效果 Fracturing & Destruction 插件使用
全文见原始链接:http://note.youdao.com/noteshare?id=ef5ef90b71da4e960e5bc0da4f3f17ec 下面是预览 示例工程链接:https://pa ...
- CentOS 7 安装Httpd(转)
实验环境:CentOS7 实验步骤: 安装httpd服务:yum -y install httpd 关闭SELinux:setenforce 0 禁用防火墙策略:iptables -F 启动httpd ...
- java后台读取配置文件中key与value -----demo2
/** * * @Title: getValue * @Description: TODO * @param key * @return import java.util.Properties; * ...
- 初识python(python的安装与运行)
python--“优雅”.“明确”.“简单”的哲学定位 一.python的安装(Windows环境下) 1.在python官网下载安装文件 python的官方网址:https://www.python ...
- 【MySQL】教程及常用工具和操作
12.MySQL菜鸟教程 http://www.runoob.com/mysql/mysql-data-types.html 3.MySQL Workbench怎么使用及其使用教程 https://j ...
- SVN专题(Visual SVN Server + TortoiseSVN + Visual SVN)
参考资料: 1.Windows环境下搭建SVN服务器.原文地址:https://blog.csdn.net/lu1024188315/article/details/74082227 2.Git|SV ...
- 浅析Web Services
Web Services 可使您的应用程序成为 Web 应用程序. Web Services 通过 Web 进行发布.查找和使用. 1.什么是Web Services? Web Services 是应 ...
- processlist中最哪些状态要引起关注
一般而言,我们在processlist结果中如果经常能看到某些SQL的话,至少可以说明这些SQL的频率很高,通常需要对这些SQL进行进一步优化. 今天我们要说的是,在processlist中,看到哪些 ...