Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required(JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required)
JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1713626] Thu, 05 November 2015 14:54 Go to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Hi,

I like to clone a git repository and i have to use credentials.

jgit version 4.2.0-SNAPSHOT


At linux (and Windows too), I get:
org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required
====
java -Dhttp.proxyHost=proxy -Dhttp.proxyPort=8080 -Dhttps.proxyHost=proxy -Dhttps.proxyPort=8080 -jar ~/jgit-cli.jar clone https://[hide]
Username for https://[hide]/info/refs?service=git-upload-pack: TheCorrectUserName
Password: TheCorrectPasswort
Cloning into 'xyz'...
org.eclipse.jgit.api.errors.TransportException:https://[hide]: 401 Authorization Required
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:140)
at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:200)
at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:134)
at org.eclipse.jgit.pgm.Clone.run(Clone.java:114)
at org.eclipse.jgit.pgm.TextBuiltin.execute(TextBuiltin.java:199)
at org.eclipse.jgit.pgm.Main.execute(Main.java:223)
at org.eclipse.jgit.pgm.Main.run(Main.java:124)
at org.eclipse.jgit.pgm.Main.main(Main.java:98)
Caused by: org.eclipse.jgit.errors.TransportException: https://[hide]: 401 Authorization Required
at org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:377)
at org.eclipse.jgit.transport.TransportHttp$SmartHttpFetchConnection.doFetch(TransportHttp.java:779)
at org.eclipse.jgit.transport.BasePackFetchConnection.fetch(BasePackFetchConnection.java:308)
at org.eclipse.jgit.transport.BasePackFetchConnection.fetch(BasePackFetchConnection.java:298)
at org.eclipse.jgit.transport.FetchProcess.fetchObjects(FetchProcess.java:245)
at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:161)
at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:122)
at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1138)
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:130)
... 7 more
Caused by: org.eclipse.jgit.errors.TransportException: https://[hide]: 401 Authorization Required
at org.eclipse.jgit.transport.TransportHttp$Service.openResponse(TransportHttp.java:876)
at org.eclipse.jgit.transport.TransportHttp$MultiRequestService.execute(TransportHttp.java:977)
at org.eclipse.jgit.transport.TransportHttp$Service$HttpExecuteStream.read(TransportHttp.java:903)
at org.eclipse.jgit.util.io.UnionInputStream.read(UnionInputStream.java:145)
at org.eclipse.jgit.util.IO.readFully(IO.java:247)
at org.eclipse.jgit.transport.PacketLineIn.readLength(PacketLineIn.java:186)
at org.eclipse.jgit.transport.PacketLineIn.readString(PacketLineIn.java:138)
at org.eclipse.jgit.transport.PacketLineIn.readACK(PacketLineIn.java:102)
at org.eclipse.jgit.transport.BasePackFetchConnection.negotiate(BasePackFetchConnection.java:663)
at org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:363)
... 15 more


With git version 2.4.3 all works fine.

Can anyone give me a hint?






Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1713639 is a reply to message #1713626] Thu, 05 November 2015 15:40 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Using Java 1.7 instead of 1.8:

org.eclipse.jgit.api.errors.TransportException: https://[hide]: 400 Bad Request
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:140)
at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:200)
at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:134)
at org.eclipse.jgit.pgm.Clone.run(Clone.java:114)
at org.eclipse.jgit.pgm.TextBuiltin.execute(TextBuiltin.java:199)
at org.eclipse.jgit.pgm.Main.execute(Main.java:223)
at org.eclipse.jgit.pgm.Main.run(Main.java:124)
at org.eclipse.jgit.pgm.Main.main(Main.java:98)
Caused by: org.eclipse.jgit.errors.TransportException: https://[hide]: 400 Bad Request
at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:510)
at org.eclipse.jgit.transport.TransportHttp.openFetch(TransportHttp.java:296)
at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:136)
at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:122)
at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1138)
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:130)
... 7 more

Using https://repo.eclipse.org/content/groups/releases/org/eclipse/jgit/org.eclipse.jgit.pgm/4.1.0.201509280440-r/org.eclipse.jgit.pgm-4.1.0.201509280440-r.sh
instead of the self build jgit-cli

has the same results
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1713687 is a reply to message #1713639] Thu, 05 November 2015 23:34 Go to previous messageGo to next message
Christian Halstrick is currently offline Christian HalstrickFriend
Messages: 274
Registered: July 2009
Senior Member
Hi,

I also see since a few days "401 Authorization Required" problems when pushing with JGit command line to github. Pushing works (for me) when JGit is used inside from inside Eclipse with EGit. I was hunting this down and found a problem with the java.net.Authenticator instances registered by JGit command line (when run inside Eclipse/EGit other Authenticators are installed which dont show this bug). When I remove the installation of java.net.Authenticator implementations in org.eclipse.jgit.pgm.Main everything works for me. I am still trying to find out whether simply removing Authenticator implementations will break other use cases. Maybe you could try whehter pushing from inside EGit/Eclipse helps you.


Ciao
Chris
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1713688 is a reply to message #1713687] Fri, 06 November 2015 00:04 Go to previous messageGo to next message
Christian Halstrick is currently offline Christian HalstrickFriend
Messages: 274
Registered: July 2009
Senior Member
See my proposal https://git.eclipse.org/r/59792

Ciao
Chris
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1713754 is a reply to message #1713688] Fri, 06 November 2015 12:37 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
addition:
with java 1.8.0_65 the error changes to:
500 Internal Server Error

going back to 1.8.0_51 it is again
401 Authorization Required
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1713770 is a reply to message #1713688] Fri, 06 November 2015 15:02 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
@Chris: Danke!

Thank you for the hint, I installed Eclipse Mars/EGIT before and it works. I am analysing, why EGITS log is slow comparing to git-scm command line. So I start comparing it with jgit.

The at the moment, the connection to the server is not important, i can do it with EGIT.

Nevertheless, I would like to use your changes you did in the morning. I cloned https://git.eclipse.org/r/jgit/jgit.git one hour ago, but i cannot find any changes from today, only from yesterday.

Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1714137 is a reply to message #1713770] Tue, 10 November 2015 08:35 Go to previous messageGo to next message
Christian Halstrick is currently offline Christian HalstrickFriend
Messages: 274
Registered: July 2009
Senior Member
Cloning doesn't help because my change is not yet accepted. If you follow the link https://git.eclipse.org/r/59792 you see instructions how to checkout that specific patchset. In this case the command would be

git fetch https://git.eclipse.org/r/a/jgit/jgit refs/changes/92/59792/2 && git checkout FETCH_HEAD


Ciao
Chris
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715413 is a reply to message #1714137] Mon, 23 November 2015 12:29 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Hi Chris,

Thank you for your instructions.
I am back to my environment i tried to access the repository you mentioned.


I need credentials/account to access it. How can i get them/it?


Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715420 is a reply to message #1715413] Mon, 23 November 2015 13:12 Go to previous messageGo to next message
Christian Halstrick is currently offline Christian HalstrickFriend
Messages: 274
Registered: July 2009
Senior Member
Sorry, my fault. The url I sent contained the '.../a/..." which enforces authentication. Try this statement:

git fetch https://git.eclipse.org/r/jgit/jgit refs/changes/92/59792/2 && git checkout FETCH_HEAD


Ciao
Chris
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715433 is a reply to message #1715420] Mon, 23 November 2015 14:28 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Ok, now I build it with:
HEAD is now at 981e696... WIP: Remove installation of Authenticators from pgm.Main

Cloning with jgit-cli it, I am getting a NullPointerException before i am asked to input my credentials

Cloning into 'xyz'...
java.lang.NullPointerException
at java.lang.String.<init>(String.java:166)
at org.eclipse.jgit.transport.HttpAuthMethod.authorize(HttpAuthMethod.java:222)
at org.eclipse.jgit.transport.TransportHttp.connect(TransportHttp.java:497)
at org.eclipse.jgit.transport.TransportHttp.openFetch(TransportHttp.java:296)
at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:136)
at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:122)
at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1151)
at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:130)
at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:200)
at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:134)
at org.eclipse.jgit.pgm.Clone.run(Clone.java:114)
at org.eclipse.jgit.pgm.TextBuiltin.execute(TextBuiltin.java:199)
at org.eclipse.jgit.pgm.Main.execute(Main.java:221)
at org.eclipse.jgit.pgm.Main.run(Main.java:122)
at org.eclipse.jgit.pgm.Main.main(Main.java:97)


Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715436 is a reply to message #1715433] Mon, 23 November 2015 14:42 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
WIth
git checkout FETCH_HEAD (at the mentioned jgit repository)
i am getting the valuable information:

HEAD is now at 981e696... WIP: Remove installation of Authenticators from pgm.Main


Jgit instead is quiet. Can i make jgit more verbose?

Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715674 is a reply to message #1715436] Wed, 25 November 2015 08:24 Go to previous messageGo to next message
Christian Halstrick is currently offline Christian HalstrickFriend
Messages: 274
Registered: July 2009
Senior Member
Strange, it works for me. At least if I rebase the change on JGits current master. Maybe thats the problem. Here is what I am doing:

> git fetch origin
> git fetch https://git.eclipse.org/r/a/jgit/jgit refs/changes/92/59792/2
From https://git.eclipse.org/r/a/jgit/jgit
 * branch            refs/changes/92/59792/2 -> FETCH_HEAD
> git checkout FETCH_HEAD
....
> git rebase origin/master 
First, rewinding head to replay your work on top of it...
Applying: WIP: Remove installation of Authenticators from pgm.Main
> mvn clean install -DskipTests
....
> java -jar org.eclipse.jgit.pgm/target/jgit-cli.jar clone https://github.com/chalstrick/dondalfi.git /tmp/dondalfi
Cloning into '/tmp/dondalfi'...

> git -C /tmp/dondalfi/ log -3 --oneline
a52dfe5 test
56e209f modified again
d24579e modified



Ciao
Chris
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715719 is a reply to message #1715674] Wed, 25 November 2015 13:10 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member

I build it again (putting the proxy to the maven environment), using
https://git.eclipse.org/r/jgit/jgit
instead of
https://git.eclipse.org/r/a/jgit/jgit

still the same stack trace with my repository,
> git fetch origin
> git fetch https://git.eclipse.org/r/a/jgit/jgit refs/changes/92/59792/2



For eclipse Mars i am using EGIT (which works together with my git server). Are there differences in the implementation of between egit (with jgit) and jgit-cli, which explains the different behavior?

Eclipse Git Team Provider 4.0.0.201506090130-r org.eclipse.egit.feature.group Eclipse EGit
Java implementation of Git 4.0.0.201506090130-r org.eclipse.jgit.feature.group Eclipse JGit

I tried to build a jgit-cli version with Git 4.0.0.201506090130-r.
>git fetch origin
>git fetch https://git.eclipse.org/r/jgit/jgit v4.0.0.201506090130-r
From https://git.eclipse.org/r/jgit/jgit
* tag v4.0.0.201506090130-r -> FETCH_HEAD

Version build is: jgit version 4.2.0-SNAPSHOT
I am getting the same error/stack trace.

Can i use a typical user login for GitHub to access the test repo https://github.com/chalstrick/dondalfi.git?







Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715834 is a reply to message #1715719] Thu, 26 November 2015 13:44 Go to previous messageGo to next message
Christian Halstrick is currently offline Christian HalstrickFriend
Messages: 274
Registered: July 2009
Senior Member
I am confused a little bit where things fail at your place. Could you configure your maven to be able to download files from the internet and the run the following commands. Please send me a trace of that:

Quote:

cd /tmp
export https_proxy=proxy:8080
git clone -q https://git.eclipse.org/r/jgit/jgit
cd jgit/
git fetch https://git.eclipse.org/r/jgit/jgit refs/changes/92/59792/2 && git checkout -q FETCH_HEAD
mvn -q clean install -DskipTests
cd ..
java -Dhttps.proxyHost=proxy -Dhttps.proxyPort=8080 -jar jgit/org.eclipse.jgit.pgm/target/jgit-cli.jar clone https://github.com/chalstrick/dondalfi.git


Ciao
Chris
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1715846 is a reply to message #1715834] Thu, 26 November 2015 15:14 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Hi Chris,
Sorry, i was not precise enough. My repository is user/password protected, your example is not. So the access to your repository works, see below:


D:\>mkdir \gittmp
D:\>export https_proxy=proxy:8080
D:\>cd \gittmp
D:\gittmp>git config --get core.autocrlf
true
D:\gittmp>git clone -q https://git.eclipse.org/r/jgit/jgit
D:\gittmp\jgit>git fetch https://git.eclipse.org/r/jgit/jgit refs/changes/92/59792/2
From https://git.eclipse.org/r/jgit/jgit
* branch refs/changes/92/59792/2 -> FETCH_HEAD
D:\gittmp\jgit>git checkout -q FETCH_HEAD
D:\gittmp\jgit>set MAVEN_OPTS= "-Dhttp.proxyHost=proxy -Dhttp.proxyPort=8080 -Dhttps.proxyHost=proxy -Dhttps.proxyPort=8080 "
D:\gittmp\jgit>mvn -q clean install -DskipTests
Warning: org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Compiler-Warnungen:
WARNING: 'org.apache.xerces.jaxp.SAXParserImpl: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.'
Warning: org.apache.xerces.parsers.SAXParser: Feature 'http://javax.xml.XMLConstants/feature/secure-processing' is not recognized.
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Warning: org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Compiler-Warnungen:
WARNING: 'org.apache.xerces.jaxp.SAXParserImpl: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.'
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Warning: org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Compiler-Warnungen:
WARNING: 'org.apache.xerces.jaxp.SAXParserImpl: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.'
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Warning: org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Compiler-Warnungen:
WARNING: 'org.apache.xerces.jaxp.SAXParserImpl: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.'
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Warning: org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
Compiler-Warnungen:
WARNING: 'org.apache.xerces.jaxp.SAXParserImpl: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.'
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://javax.xml.XMLConstants/property/accessExternalDTD' is not recognized.
Warning: org.apache.xerces.parsers.SAXParser: Property 'http://www.oracle.com/xml/jaxp/properties/entityExpansionLimit' is not recognized.
[WARNING] Map in class org.apache.maven.plugins.shade.resource.ManifestResourceTransformer declares value type as: class java.util.jar.Attributes but saw: class java.lang.String at runtime
[WARNING] Map in class org.apache.maven.plugins.shade.resource.ManifestResourceTransformer declares value type as: class java.util.jar.Attributes but saw: class java.lang.String at runtime

D:\gittmp\jgit>cd ..
D:\gittmp>java -Dhttps.proxyHost=proxy -Dhttps.proxyPort=8080 -jar jgit/org.eclipse.jgit.pgm/target/jgit-cli.jar clone https://github.com/chalstrick/dondalfi.git
Cloning into 'dondalfi'...













Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1716743 is a reply to message #1715846] Mon, 07 December 2015 22:35 Go to previous messageGo to next message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1268
Registered: July 2009
Senior Member
Could you try https://git.eclipse.org/r/#/c/62120/ ?
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1716835 is a reply to message #1716743] Tue, 08 December 2015 13:05 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Matthias Sohn wrote on Mon, 07 December 2015 22:35
Could you try https://git.eclipse.org/r/#/c/62120/ ?

Do i have to use it on top of refs/changes/92/59792/2 (https://git.eclipse.org/r/59792)?

I did it only with https://git.eclipse.org/r/#/c/62120/
D:\jgit99\>git clone https://git.eclipse.org/r/jgit/jgit
D:\jgit99\>cd jgit
D:\jgit99\jgit>git fetch https://git.eclipse.org/r/a/jgit/jgit  refs/changes/20/62120/1 
D:\jgit99\jgit>git checkout FETCH_HEAD

Cloning into 'xxxxx'...
org.eclipse.jgit.api.errors.TransportException: https://yyy/git/xxxxx: 401 Authorization Required
        at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:139)
        at org.eclipse.jgit.api.CloneCommand.fetch(CloneCommand.java:200)
        at org.eclipse.jgit.api.CloneCommand.call(CloneCommand.java:134)
        at org.eclipse.jgit.pgm.Clone.run(Clone.java:114)
        at org.eclipse.jgit.pgm.TextBuiltin.execute(TextBuiltin.java:199)
        at org.eclipse.jgit.pgm.Main.execute(Main.java:223)
        at org.eclipse.jgit.pgm.Main.run(Main.java:124)
        at org.eclipse.jgit.pgm.Main.main(Main.java:98)
Caused by: org.eclipse.jgit.errors.TransportException: https://kazan.atosworldline.com/git/wlp-fo: 401 Authorization Required
        at org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:377)
        at org.eclipse.jgit.transport.TransportHttp$SmartHttpFetchConnection.doFetch(TransportHttp.java:779)
        at org.eclipse.jgit.transport.BasePackFetchConnection.fetch(BasePackFetchConnection.java:308)
        at org.eclipse.jgit.transport.BasePackFetchConnection.fetch(BasePackFetchConnection.java:298)
        at org.eclipse.jgit.transport.FetchProcess.fetchObjects(FetchProcess.java:245)
        at org.eclipse.jgit.transport.FetchProcess.executeImp(FetchProcess.java:161)
        at org.eclipse.jgit.transport.FetchProcess.execute(FetchProcess.java:122)
        at org.eclipse.jgit.transport.Transport.fetch(Transport.java:1179)
        at org.eclipse.jgit.api.FetchCommand.call(FetchCommand.java:130)
        ... 7 more
Caused by: org.eclipse.jgit.errors.TransportException: https://kazan.atosworldline.com/git/wlp-fo: 401 Authorization Required
        at org.eclipse.jgit.transport.TransportHttp$Service.openResponse(TransportHttp.java:875)
        at org.eclipse.jgit.transport.TransportHttp$MultiRequestService.execute(TransportHttp.java:977)
        at org.eclipse.jgit.transport.TransportHttp$Service$HttpExecuteStream.read(TransportHttp.java:903)
        at org.eclipse.jgit.util.io.UnionInputStream.read(UnionInputStream.java:145)
        at org.eclipse.jgit.util.IO.readFully(IO.java:247)
        at org.eclipse.jgit.transport.PacketLineIn.readLength(PacketLineIn.java:186)
        at org.eclipse.jgit.transport.PacketLineIn.readString(PacketLineIn.java:138)
        at org.eclipse.jgit.transport.PacketLineIn.readACK(PacketLineIn.java:102)
        at org.eclipse.jgit.transport.BasePackFetchConnection.negotiate(BasePackFetchConnection.java:663)
        at org.eclipse.jgit.transport.BasePackFetchConnection.doFetch(BasePackFetchConnection.java:363)
        ... 15 more



Testing with git (scm): works

[Updated on: Tue, 08 December 2015 13:15]

Report message to a moderator

Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1716952 is a reply to message #1716835] Wed, 09 December 2015 09:37 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Can i do something else, making some SSL/TLS connections debugging?
Debugging SSL/TLS connections
https://docs.oracle.com/javase/7/docs/technotes/guides/security/jsse/ReadDebug.html
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1717441 is a reply to message #1716952] Sun, 13 December 2015 19:22 Go to previous messageGo to next message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1268
Registered: July 2009
Senior Member
Try the third patchset we fixed another issue present in earlier patchsets of this change
git fetch https://git.eclipse.org/r/a/jgit/jgit refs/changes/20/62120/3 && git checkout FETCH_HEAD

We use mitmproxy [1] for debugging problems involving TLS connections

[1] http://mitmproxy.org/
Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1717471 is a reply to message #1717441] Mon, 14 December 2015 09:23 Go to previous messageGo to next message
Anselm D. is currently offline Anselm D.Friend
Messages: 49
Registered: October 2015
Member
Thank you, this one works:
D:\jgit99\jgit>git fetch https://git.eclipse.org/r/jgit/jgit refs/changes/20/62120/3 & git checkout FETCH_HEAD
remote: Counting objects: 1793, done
remote: Finding sources: 100% (51/51)
emote: Total 51 (delta 14), reused 50 (delta 14)
Unpacking objects: 100% (51/51), done.
From https://git.eclipse.org/r/jgit/jgit
 * branch            refs/changes/20/62120/3 -> FETCH_HEAD
Warning: you are leaving 1 commit behind, not connected to
any of your branches:

  981e696 WIP: Remove installation of Authenticators from pgm.Main

If you want to keep it by creating a new branch, this may be a good time
to do so with:

 git branch <new-branch-name> 981e696

HEAD is now at bb26afe... Fix push with jgit pgm failing with "unauthorized"


Matthias Sohn wrote on Sun, 13 December 2015 19:22
Try the third patchset we fixed another issue present in earlier patchsets of this change
git fetch https://git.eclipse.org/r/a/jgit/jgit refs/changes/20/62120/3 && git checkout FETCH_HEAD

Re: JGIT: org.eclipse.jgit.api.errors.TransportException: https://[hide]: 401 Authorization Required [message #1717963 is a reply to message #1717471] Fri, 18 December 2015 08:31 Go to previous message
Matthias Sohn is currently offline Matthias SohnFriend
Messages: 1268
Registered: July 2009
Senior Member
The fix https://git.eclipse.org/r/#/c/62120/ was submitted
Previous Topic:Encryption with JGIT
Next Topic:Create Listener for Git Event using EGIT-plugins
Goto Forum:
  


Current Time: Tue Apr 16 16:59:17 GMT 2024

Powered by FUDForum. Page generated in 0.54466 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top