我生成了一个个人访问令牌,用于 Windows 通用凭据和 git 凭据管理器。我正在使用带有此配置的 git 64 位版本 2.21.0.windows.1
GCM_AUTHORITY=NTLM
GCM_HTTP_TIMEOUT=100000
GCM_PRESERVE=true
GCM_TOKEN_DURATION=24
GCM_TRACE=C:\logs\git-cm.log
GCM_VALIDATE=false
但并非总是“git clone”命令成功抱怨身份验证错误
fatal: Authentication failed for 'https://tfs...
这里是 GCM 的日志:
11:56:09.657834 ...\Common.cs:744 trace: [Main] git-credential-manager (v1.18.4) 'get'
11:56:09.769222 ...\Git\Where.cs:348 trace: [FindGitInstallations] found 1 Git installation(s).
11:56:09.778231 ...Configuration.cs:222 trace: [LoadGitConfiguration] git All config read, 14 entries.
11:56:09.779232 ...\Common.cs:435 trace: [LoadOperationArguments] authority = 'NTLM'.
11:56:09.783270 ...\Common.cs:497 trace: [LoadOperationArguments] validate = 'False'.
11:56:09.783270 ...\Common.cs:521 trace: [LoadOperationArguments] preserve = 'True'.
11:56:09.784271 ...\Common.cs:596 trace: [LoadOperationArguments] tokenDuration = '24'.
11:56:09.784271 ...\Common.cs:691 trace: [LoadOperationArguments] httpTimeout = '100000'.
11:56:09.868367 ...\Common.cs:224 trace: [CreateAuthentication] authority for 'https://tfs.<<domain>>/' is basic with NTLM=Always.
11:56:09.870348 ...\Common.cs:765 trace: [QueryCredentials] querying 'Ntlm' for credentials.
11:56:09.870348 ...\Common.cs:915 trace: [QueryCredentials] 'https://tfs.<<domain>>/' is NTLM.
11:56:10.085193 ...\Common.cs:744 trace: [Main] git-credential-manager (v1.18.4) 'erase'
11:56:10.185836 ...\Git\Where.cs:348 trace: [FindGitInstallations] found 1 Git installation(s).
11:56:10.201430 ...Configuration.cs:222 trace: [LoadGitConfiguration] git All config read, 14 entries.
11:56:10.202158 ...\Common.cs:435 trace: [LoadOperationArguments] authority = 'NTLM'.
11:56:10.206490 ...\Common.cs:497 trace: [LoadOperationArguments] validate = 'False'.
11:56:10.206490 ...\Common.cs:521 trace: [LoadOperationArguments] preserve = 'True'.
11:56:10.206490 ...\Common.cs:596 trace: [LoadOperationArguments] tokenDuration = '24'.
11:56:10.206490 ...\Common.cs:691 trace: [LoadOperationArguments] httpTimeout = '100000'.
11:56:10.237784 ...\Program.cs:369 trace: [Erase] preserve = true, canceling erase request.
11:56:10.411841 ...\Common.cs:744 trace: [Main] git-credential-manager (v1.18.4) 'erase'
11:56:10.528564 ...\Git\Where.cs:348 trace: [FindGitInstallations] found 1 Git installation(s).
11:56:10.528564 ...Configuration.cs:222 trace: [LoadGitConfiguration] git All config read, 14 entries.
11:56:10.528564 ...\Common.cs:435 trace: [LoadOperationArguments] authority = 'NTLM'.
11:56:10.544186 ...\Common.cs:497 trace: [LoadOperationArguments] validate = 'False'.
11:56:10.544186 ...\Common.cs:521 trace: [LoadOperationArguments] preserve = 'True'.
11:56:10.544186 ...\Common.cs:596 trace: [LoadOperationArguments] tokenDuration = '24'.
11:56:10.544186 ...\Common.cs:691 trace: [LoadOperationArguments] httpTimeout = '100000'.
11:56:10.575440 ...\Program.cs:369 trace: [Erase] preserve = true, canceling erase request.
知道发生了什么吗?
谢谢