Applet Security -

When an app is accessed through https, if there is no trust between app server and browser jre, client jvm may spit SSL HandShake Error. Error may go like this -
Error Occured during session initialization: Error SSL connecting to server:9446: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

Its very simple to solve this. One needs to import client certificate into jre/lib/security/cacerts which is the trust store of the JVM.
example -
"C:\Program Files\Java\jre1.5.0_11\bin\keytool" -import -trustcacerts -keystore "C:\Program Files\Java\jre1.5.0_11\lib\security\cacerts" -storepass changeit -noprompt -alias ALIAS_NAME -file "\CERTIFICATE_NAME"

No comments: