Wiki source code of SSL Certificate Error

Last modified by Eleni Cojocariu on 2026/08/03 13:18

Show last authors
1 Sometimes, XWiki fails to access ##HTTPS## websites, and logs an SSL handshake exception:
2
3 {{code language="none"}}
4 2017-03-14 20:40:17,494 [http://dwswiki10:8080/xwiki/bin/admin/XWiki/XWikiPreferences?editor=globaladmin&section=XWiki.AddExtensions] ERROR aultExtensionRepositoryManager - Failed to search on repository [store.xwiki.com:xwiki:https://store.xwiki.com/xwiki/rest] with query [org.xwiki.extension.repository.search.ExtensionQuery@78b5e254]. Ignore and go to next repository.
5 org.xwiki.extension.repository.search.SearchException: Failed to search extensions based on pattern []
6 at org.xwiki.extension.repository.xwiki.internal.XWikiExtensionRepository.search(XWikiExtensionRepository.java:434)
7 ...
8 Caused by: java.io.IOException: Failed to request [https://store.xwiki.com/xwiki/rest/repository/search?start=0&number=20&q=]
9 at org.xwiki.extension.repository.xwiki.internal.XWikiExtensionRepository.getRESTResource(XWikiExtensionRepository.java:246)
10 ...
11 Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
12 at sun.security.ssl.Alerts.getSSLException(Alerts.java:192)
13 ...
14 Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
15 at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:387)
16 ...
17 Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
18 at sun.security.provider.certpath.SunCertPathBuilder.build(SunCertPathBuilder.java:145)
19 ...
20 {{/code}}
21
22 === Cause ===
23
24 This usually happens because the [[Java Runtime Environment (JRE)>>dev:Community.SupportStrategy.JavaSupportStrategy.WebHome]] used to run XWiki is too old to validate the SSL certificate of the target server. Specifically, versions of Java 8 older than update 101 do not include the necessary root certificates to validate some HTTPS connections.
25
26 === Solution ===
27
28 Upgrade Java 8 to at least update 101 (no need to jump to Java 9 or higher). You can check your Java version: {{code language="none"}}java -version{{/code}}. Restart your application server (Tomcat, Jetty, etc.) after upgrading Java so that XWiki picks up the new runtime.

Get Connected