SSLHandshakeException ValidatorException No trusted certificate found
Client - server program. Connection from client to server is realized using SSL + keystore and truststore. Using JBoss 4.2.
When I try connect for the firs time, everything is ok. There is functionality on client, if user does no action in few minutes program suggests to repeat login operation to continue session. If I LogIn in few minutes after login dialog is shown everything is still ok., but IF I WAIT MORE THAN HOUR - I GET ERROR: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: No trusted certificate found. And ofcource cannot connect.
Tried: Re-add keystore and trustStore to SSLContext on Login - had not helped.
SSLContext sc = SSLContext.getInstance("SSL"); sc.init(keyManagers, trustManagers, null); Application.keyManagers = keyManagers; Application.trustManagers = trustManagers; SSLContext.setDefault(sc);
Question: Can someone suggest any operation should be done? Is there any time limits on certificate acception?
The below link might help you out, these are common issues, the server is able to present the certificate, issue might be importing certificates into trustore and public key into keystore.