sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target at java.base/sun.security.provider.certpath.SunCertPathBuilder.build(SunCertPathBuilder.java:141) at java.base/sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:126) at java.base/java.security.cert.CertPathBuilder.build(CertPathBuilder.java:297) at java.base/sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:380) Caused: sun.security.validator.ValidatorException: PKIX path building failed at java.base/sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:385) at java.base/sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:290) at java.base/sun.security.validator.Validator.validate(Validator.java:264) at java.base/sun.security.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:321) at java.base/sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:221) at java.base/sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:129) at java.base/sun.security.ssl.CertificateMessage$T12CertificateConsumer.checkServerCerts(CertificateMessage.java:626) Caused: javax.net.ssl.SSLHandshakeException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:131) at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:321) at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:264) at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:259) at java.base/sun.security.ssl.CertificateMessage$T12CertificateConsumer.checkServerCerts(CertificateMessage.java:642) at java.base/sun.security.ssl.CertificateMessage$T12CertificateConsumer.onCertificate(CertificateMessage.java:461) at java.base/sun.security.ssl.CertificateMessage$T12CertificateConsumer.consume(CertificateMessage.java:361) at java.base/sun.security.ssl.SSLHandshake.consume(SSLHandshake.java:392) at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:448) at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:425) at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:178) at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:164) at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1152) at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1063) at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:402) at java.base/sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:567) at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185) at java.base/sun.net.www.protocol.http.HttpURLConnection.followRedirect0(HttpURLConnection.java:2768) at java.base/sun.net.www.protocol.http.HttpURLConnection.followRedirect(HttpURLConnection.java:2680) at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1843) at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1509) at java.base/java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:527) at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:329) at hudson.FilePath.installIfNecessaryFrom(FilePath.java:874) Caused: java.io.IOException: Failed to install https://services.gradle.org/distributions/gradle-5.5.1-bin.zip to /home/build/jenkins-test/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.5 at hudson.FilePath.installIfNecessaryFrom(FilePath.java:938) at hudson.FilePath.installIfNecessaryFrom(FilePath.java:846) at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77) at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:69) at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109) at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206) at hudson.plugins.gradle.GradleInstallation.forNode(GradleInstallation.java:92) at hudson.plugins.gradle.GradleInstallation.forNode(GradleInstallation.java:30) at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152) at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133) at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:834)
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/93ecd2ab-622a-4306-ad97-6546972c3471%40googlegroups.com.
Unpacking https://services.gradle.org/distributions/gradle-5.5.1-bin.zip to /home/build/jenkins-test/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.5 on master-sles12.3-x86_64_2
ERROR: Failed to download https://services.gradle.org/distributions/gradle-5.5.1-bin.zip from agent; will retry from master sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target at sun.security.provider.certpath.SunCertPathBuilder.build(SunCertPathBuilder.java:141) at sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:126) at java.security.cert.CertPathBuilder.build(CertPathBuilder.java:280) at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:392) Caused: sun.security.validator.ValidatorException: PKIX path building failed at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:397) at sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:302) at sun.security.validator.Validator.validate(Validator.java:262) at sun.security.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:330) at sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:237) at sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:132) at sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1621) Also: hudson.remoting.Channel$CallSiteStackTrace: Remote call to master-sles12.3-x86_64_2 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1743) at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357) at hudson.remoting.Channel.call(Channel.java:957) at hudson.FilePath.act(FilePath.java:1070) at hudson.FilePath.act(FilePath.java:1059) at hudson.FilePath.installIfNecessaryFrom(FilePath.java:913) at hudson.FilePath.installIfNecessaryFrom(FilePath.java:846) at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77) at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:69) at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109) at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206) at hudson.plugins.gradle.GradleInstallation.forNode(GradleInstallation.java:92) at hudson.plugins.gradle.GradleInstallation.forNode(GradleInstallation.java:30) at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152) at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133) at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:834) Caused: javax.net.ssl.SSLHandshakeException at sun.security.ssl.Alerts.getSSLException(Alerts.java:192) at sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1946) at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:316) at sun.security.ssl.Handshaker.fatalSE(Handshaker.java:310) at sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1639) at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:223) at sun.security.ssl.Handshaker.processLoop(Handshaker.java:1037) at sun.security.ssl.Handshaker.process_record(Handshaker.java:965) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1064) at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1367) at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1395) at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1379) at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:559) at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185) at sun.net.www.protocol.http.HttpURLConnection.followRedirect0(HttpURLConnection.java:2735) at sun.net.www.protocol.http.HttpURLConnection.followRedirect(HttpURLConnection.java:2647) at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1830) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1498) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:268) at java.net.URL.openStream(URL.java:1057) at hudson.FilePath$Unpack.invoke(FilePath.java:949) at hudson.FilePath$Unpack.invoke(FilePath.java:943) at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3050) at hudson.remoting.UserRequest.perform(UserRequest.java:212) at hudson.remoting.UserRequest.perform(UserRequest.java:54) at hudson.remoting.Request$2.run(Request.java:369) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)javax.net.ssl.SSLHandshakeException: Received fatal alert: access_denied at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:131) at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117) at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:308) at java.base/sun.security.ssl.Alert$AlertConsumer.consume(Alert.java:285) at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:181) at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:164) at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1152) at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1063) at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:402) at java.base/sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:567) at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185) at java.base/sun.net.www.protocol.http.HttpURLConnection.followRedirect0(HttpURLConnection.java:2768) at java.base/sun.net.www.protocol.http.HttpURLConnection.followRedirect(HttpURLConnection.java:2680) at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1843) at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1509) at java.base/sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:3084) at java.base/java.net.URLConnection.getHeaderFieldLong(URLConnection.java:636) at java.base/java.net.URLConnection.getContentLengthLong(URLConnection.java:508) at java.base/java.net.URLConnection.getContentLength(URLConnection.java:492) at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.getContentLength(HttpsURLConnectionImpl.java:389) at org.jvnet.robust_http_client.RetryableHttpStream.<init>(RetryableHttpStream.java:90) Caused: javax.net.ssl.SSLHandshakeException: Received fatal alert: access_denied at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490) at java.base/sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1963) at java.base/sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1958) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1957) at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1525) at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1509) at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:245) at org.jvnet.robust_http_client.RetryableHttpStream.getStream(RetryableHttpStream.java:98) at org.jvnet.robust_http_client.RetryableHttpStream.<init>(RetryableHttpStream.java:91) at hudson.ProxyConfiguration.getInputStream(ProxyConfiguration.java:285) at hudson.FilePath.installIfNecessaryFrom(FilePath.java:924) Caused: java.io.IOException: Failed to install https://services.gradle.org/distributions/gradle-5.5.1-bin.zip to /home/build/jenkins-test/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.5 at hudson.FilePath.installIfNecessaryFrom(FilePath.java:938) at hudson.FilePath.installIfNecessaryFrom(FilePath.java:846) at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77) at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:69) at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109) at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206) at hudson.plugins.gradle.GradleInstallation.forNode(GradleInstallation.java:92) at hudson.plugins.gradle.GradleInstallation.forNode(GradleInstallation.java:30) at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152) at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133) at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:834)
I would guess that you may already be using a modified cacerts file which does not include the authority that is certifying the validity of the SSL certificate on the gradle site.When I download from that URL, my web browser reports no issues from Google Chrome on Windows and no issues from wget on a FreeBSD computer.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkins...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/93ecd2ab-622a-4306-ad97-6546972c3471%40googlegroups.com.
--Thanks!Mark Waite
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/4f6bdea1-95fd-4237-a7d7-b2f4c0834046%40googlegroups.com.
Maybe this is the time to reconfigure the tool installer to download from a locally cached copy of the tool instead of pulling it from the internet?I've had good results with that technique by placing zip files of the tool installers inside my network and then configuring the tool installer to use the copy from my network instead of the copy from the internet.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/4f6bdea1-95fd-4237-a7d7-b2f4c0834046%40googlegroups.com.
--Thanks!Mark Waite
wget --quiet https://nexus.company.no:8443/repository/gradle-distributions/gradle-5.5.1-bin.zip
unzip -qq gradle-5.5.1-bin.zip
mv gradle-5.5.1/* .
rmdir gradle-5.5.1
rm gradle-5.5.1-bin.zip
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/af4494fc-4010-4421-a9c3-b87406426b03%40googlegroups.com.
Personally with Gradle I've always found it easier to use Gradle Wrapper instead of full installs.Don't know if that's an option for you or not.Richard.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/af4494fc-4010-4421-a9c3-b87406426b03%40googlegroups.com.
gradle wrapper --gradle-version=5.5.1
./gradlew -Dhttps.proxyHost=proxy.company.com -Dhttps.proxyPort=3128 --version
Unpacking https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.6.1/apache-maven-3.6.1-bin.zip to /home/build/jenkins/tools/hudson.tasks.Maven_MavenInstallation/maven-3.6.1 on sles12.3-x86_64_1
Unpacking https://services.gradle.org/distributions/gradle-5.6.2-bin.zip to
/home/build/jenkins/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.6.2 on sles12.3-x86_64_1
ERROR: Failed to download https://services.gradle.org/distributions/gradle-5.6.2-bin.zip from agent; will retry from master
sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
ERROR: Failed to download https://services.gradle.org/distributions/gradle-5.6.2-bin.zip from agent; will retry from mastersun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested targetWhich makes me believe that the Gradle tool does not use Jenkins Proxy settings, while Maven tools does use it.
--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAMo7PtLJW%2BeMQ-509sB%2Bv%2BdAtz_%3DDudWMsiE-eCdZYfduAPcyA%40mail.gmail.com.
I’ve always relied on projects supplying the gradle wrapper instead... that might be a good alternative if you can’t upgrade the JRE
On Mon, Sep 23, 2019 at 05:37 Daniel Beck <db...@cloudbees.com> wrote:
--On Mon, Sep 23, 2019 at 2:28 PM Sverre Moe <sver...@gmail.com> wrote:ERROR: Failed to download https://services.gradle.org/distributions/gradle-5.6.2-bin.zip from agent; will retry from mastersun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested targetWhich makes me believe that the Gradle tool does not use Jenkins Proxy settings, while Maven tools does use it.The error means it's an SSL issue. If you're on an old JRE, update it.
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkins...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/a8ae71dc-3515-499c-a038-26a80eebc3a0%40googlegroups.com.
Daniel Beck
Senior Software Engineer
CloudBees, Inc.
Result: PK B� O apache-maven-3.6.2/PK =� O apache-maven-3.6.2/li
Run the following in the Jenkins script console:hudson.ProxyConfiguration.getInputStream(new URL("https://services.gradle.org/distributions/gradle-5.6.2-bin.zip")).text.substring(0, 100)Note that this loads the entire downloaded file, if successful, into memory, so not quite production quality code ;-)Replace the URL as needed to try whatever URLs are listed as being downloaded with the different installers. The expectation for zip files is that the output starts with "PK". If the same exception gets thrown for Groovy/Gradle, while Maven works, it's SSL after all. (Gradle Wrapper would run probably on a different machine, with different JRE, so that doesn't tell you much.)
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/a8ae71dc-3515-499c-a038-26a80eebc3a0%40googlegroups.com.
/jenkins/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.6/gradle-5.6.1
/jenkins/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.6
${gradleTool}/bin/gradle
Unpacking https://nexus.company.no:8443/repository/gradle-distributions/gradle-5.6.1-bin.zip to /home/build/jenkins/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.6 on sles12.3-x86_64_4
+ /home/build/jenkins/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.6/bin/gradle -version
/home/build/jenkins/workspace/pipeline-tests/pipeline-gradle-tools@tmp/durable-81b2542a/script.sh: line 1: /home/build/jenkins/tools/hudson.plugins.gradle.GradleInstallation/gradle-5.6/bin/gradle: No such file or directory