Strange behaviour when using the eclipse gradle plugin : SSLPeerUnverifiedException: peer not authentificated

(Nelson) #1


Let me mention that this could be no gradle problem at all but after two days of investigating I try to get some new points of view. I face a strange problem when using the eclipse gradle plugin. It occurs when I connect to our https ivy repository - when running the refresh dependencies task from the plugin it ends up with a peer not authentificated

When I run it from command line everything works fine.

The certificate that is needed is added in the jdks cacerts.

The Problem only occurs on my Windows7 x64 bit machine. On my other pc (winXP x32) the plugin works super just like the command line and certificate is the same.

My question is what may be the problem for this behavior as I have no more ideas what to check out. I tried this with a eclipse 4.2 EE (x64) version installing the plugins and also a new STS 2.9.2 but the result is the same. What makes me also crazy is that the plugin always switches the gradle version from the 1.0 version i want to use to a 1.0 Milestone-7 version and I don’t get it how to stop this. I don’t know if this has something to do with the problem but from command line and the 1.0 version it works… anyways … I’m thankful for any suggestion about the problem regards M.

(Peter Niederwieser) #2

Regarding the plugin not remembering the configured Gradle version, I’ve seen this behavior too. I suggest to file an issue with STS.

The other issue sounds like Gradle might be running with different JDKs/trust stores when run from the command line and Eclipse. I’d make the build script print the values of the ‘java.home’ and ‘’ system properties to see if they are different.

(Nelson) #3

Finally I got it solved . Thank you Peter - yesterday I had a quick look on it trying out your suggestion but due to time pressure i draw the wrong conclusions. The problem was cleared after I found out that using a certain JDK also crushed when running

over command line. After starting the refresh-dependencies task with -Dssl.debug=true

i noticed that the certificate was not listed.

Somehow I must have mixed up my administration console with a none a admin console so that certificate was not added although i did get a “certificate was added to keystore message”. After adding the certificate with admin rights it all works.