I have a web application that connects to a https site. For that I have to install the certificate in the cacerts in lib/security folder. I would like to create a truststore and
The easiest way is to set a system property when launching the java process: -Djavax.net.ssl.trustStore=...
This is used by the default TrustManager, as described in http://docs.oracle.com/javase/1.5.0/docs/guide/security/jsse/JSSERefGuide.html#X509TrustManager
Alternatively, override the TrustManager as described in the next paragraph in the same document.