Symptoms
When Connecting to LDAP or JIRA or Other Services via SSL or Setting Up Trusted Communication between JIRA and Confluence, you must import the cert into your keystore. If this hasn't happened, the following error appears in the logs:
This is different from adding SSL to your server.
Cause
The cert from the keystore does not match the cert from the server.
If are using a Subject Alternative Name (SAN) record in the certificate to apply to your server, then you have probably hit this Java bug: 6668231. Upgrading to the most recent Java version should help, or alternatively you can use a certificate that contains the approrpiate server name in the Common Name (CN) field. |
Resolution
- Make sure you have imported your certificates into the keystore accoring to the Connect to LDAP or Other Services Via SSL instructions.
- Make sure any certificates have been imported into the correct keystore; you may have multiple JDKs. See Installing Java for Confluence.
- Check to see that the correct keystore is in use. It should be in your JDK, not your JRE. Make sure the system is picking up the correct JDK. Try echo %JAVA_HOME% (Windows) or export $JAVA_HOME (Linux), and compare it to the value shown in
Administration >> System Information.
| Still having problems? Try SSLPoke to see if your keystore has the right certificates. It simply connects to a SSL service, sends a byte of input, and watches the output.
|
| Still having problems after that? A copy of Andreas Sterben's original blog describes a process for importing the certificates automatically. The source is are attached to this page. To use it:
|
Add your vote to have Confluence detect SSL certificates automatically. |
Related Content





8 Comments
Hide/Show CommentsJun 30, 2010
Vincent Choy [Atlassian]
If issue happens from Confluence Administrator Console -> Plugin Repository,
The SSL certificate to add to the key chain is: https://studio.plugins.atlassian.com
Nov 04, 2010
Brendan Patterson
The current version of Java1.6_x on Linux seems to expect the cacerts file to live in:
$JAVA_HOME/jre/lib/security
not
$JAVA_HOME/lib/security
That threw me, but this page and SSLPoke saved me - thanks for writing it!!
Feb 09, 2011
Shrike
Section "Still having problems?" isn't clear:
p.4
"Move now to test port 636 for LDAPS connections". What is it about?
b. "Check for the presence of a -Djavax.net.ssl.trustStore parameter. " - check where?
Aug 31, 2011
Greg Redl
This article should help you locate the startup parameters - http://confluence.atlassian.com/display/JIRA/Setting+Properties+and+Options+on+Startup
Aug 31, 2011
Greg Redl
Excellent article.
Where exactly am I saving the SSLPoke.class file to so that I can run the listed commands?
Sep 01, 2011
Greg Warner
The link to Andreas Sterben's article is no longer valid.
Sep 07, 2011
Jeremy Largman [Atlassian]
Thanks. It got moved when Oracle took over. I've update the page.
Dec 07, 2011
Fujitsu Karlskrona
We found that adding the cert from https://studio.plugins.atlassian.com wasn't enough
We had to add the cert from https://plugins.atlassian.com as well
I got the certificate using
openssl s_client -connect plugins.atlassian.com:443
I added the certificare info to a file and imported to both my confluence user's private keystore and java's keystore
keytool -import -alias plugins.atlassian.com -file confPluginExch.cer -keystore .keystore
keytool -import -alias plugins.atlassian.com -file confPluginExch.cer -keystore $JAVA_HOME/jre/lib/security/cacerts