How to trust lets encrypt certificate with Java

30.07.2016 06:34:06

Let's Encrypt root certificate still isn't trusted. Shame on you, Oracle. If you want to trust website using it, perform these steps:

First you must have your chain.pem file (out-of-the-box it's here: /etc/letsencrypt/live/ Next run:

keytool -trustcacerts -keystore $JAVA_HOME/jre/lib/security/cacerts -storepass changeit -noprompt -importcert -file chain.pem

Note: If you use Eclipse, make sure you're using the JDK (not JRE). Also if you have multiple JDKs, make sure you use the right one.

EDIT: Since Java 8u101 is Let's encrypt trusted! YAY!

© Jiri Pinkas | this project on GitHub | related: JavaVids | Maven Central Repository Search | Java školení

Top Java Blogs is a Java blog aggregator (with English-written blogs only) focused on Java SE, Java EE, Spring Framework and Hibernate.

Made better & faster using Java Profiler