microsoft / Git-Credential-Manager-for-Mac-and-Linux

Git Credential Manager for Mac and Linux stores credentials for Git version control securely. Provides secure logon for Visual Studio Team Services (visualstudio.com).
Other
406 stars 240 forks source link

GCM fails on Mac OS with unexpected error #84

Closed sakthiyuvaraj closed 6 years ago

sakthiyuvaraj commented 6 years ago

Sakthis-MBP:repo sasakthi$ git clone https://msasg.visualstudio.com/DefaultCollection/Bing_Geospatial/_git/NativeMapClient nmc Cloning into 'nmc'... Configuration::loadGitConfiguration Configuration::ParseGitConfig credential.helper = !/Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Home/bin/java -Ddebug=true -Djava.net.useSystemProxies=true -jar /usr/local/Cellar/git-credential-manager/2.0.3/libexec/git-credential-manager-2.0.3.jar Program::loadOperationArguments Configuration::tryGetEntry Configuration::tryGetEntry Configuration::tryGetEntry Configuration::tryGetEntry Configuration::tryGetEntry Configuration::tryGetEntry Program::EnableTraceLogging Program::get targetUri = https://msasg.visualstudio.com/ Program::ComponentFactory::createSecureStore Getting a persistent token store that must be secure Getting a persistent credential store that must be secure Program::createAuthentication detecting authority type BaseVsoAuthentication::getAuthentication BaseVsoAuthentication::detectAuthority detected visualstudio.com, checking AAD vs MSA server has responded AAD authority for tenant '72f988bf-86f1-41af-91ab-2d7cd011db47' detected authority is Azure Directory BaseVsoAuthentication::getCredentials SecretStore::getTargetName Secret::uriToName target name = gcm4ml:git:https://msasg.visualstudio.com SecretStore::readCredentials SecretCache::readCredentials SecretCache::_getTargetName Secret::uriToName target name = gcm4ml:git:https://msasg.visualstudio.com BaseSecureStore::readCredentials successfully retrieved stored credentials, updating credential cache BaseVsoAuthentication::validateCredentials VsoAzureAuthority::validateCredentials Fatal error encountered. Details: java.lang.Error: unexpected error at com.microsoft.alm.authentication.VsoAzureAuthority.validateCredentials(VsoAzureAuthority.java:214) at com.microsoft.alm.authentication.BaseVsoAuthentication.validateCredentials(BaseVsoAuthentication.java:204) at com.microsoft.alm.gitcredentialmanager.Program.get(Program.java:322) at com.microsoft.alm.gitcredentialmanager.Program.get(Program.java:293) at com.microsoft.alm.gitcredentialmanager.Program.access$200(Program.java:63) at com.microsoft.alm.gitcredentialmanager.Program$3.call(Program.java:284) at com.microsoft.alm.gitcredentialmanager.Program$3.call(Program.java:281) at com.microsoft.alm.gitcredentialmanager.Program.innerMain(Program.java:195) at com.microsoft.alm.gitcredentialmanager.Program.main(Program.java:123) Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter at com.microsoft.alm.secret.Credential.contributeHeader(Credential.java:125) at com.microsoft.alm.authentication.VsoAzureAuthority.createConnectionDataRequest(VsoAzureAuthority.java:315) at com.microsoft.alm.authentication.VsoAzureAuthority.validateCredentials(VsoAzureAuthority.java:199) ... 8 more Caused by: java.lang.ClassNotFoundException: javax.xml.bind.DatatypeConverter at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:582) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:190) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:499) ... 11 more fatal: credential helper '!/Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Home/bin/java -Ddebug=true -Djava.net.useSystemProxies=true -jar /usr/local/Cellar/git-credential-manager/2.0.3/libexec/git-credential-manager-2.0.3.jar' told us to quit Sakthis-MBP:repo sasakthi$

egidiocs commented 6 years ago

the same here... High Sierra java version "10.0.1" 2018-04-17 Java(TM) SE Runtime Environment 18.3 (build 10.0.1+10)

solved using https://github.com/Microsoft/Git-Credential-Manager-for-Mac-and-Linux/issues/71

git config --global credential.helper '!java --add-modules java.xml.bind -Ddebug=true -Djava.net.useSystemProxies=true -jar /usr/local/Cellar/git-credential-manager/2.0.3/libexec/git-credential-manager-2.0.3.jar'

novak commented 6 years ago

This issue should be resolved in GCM version 2.0.4. Feel free to re-open this issue if version 2.0.4 does not fix your issue.