-
Bug
-
Resolution: Done
-
Major
-
None
-
None
-
False
-
False
-
Undefined
-
javax.security.cert.X509Certificate was deprecated in JDK 9 in favour of java.security.cert.X509Certificate.
Because of some classes have been removed in JDK 15, invoking javax.security.cert.X509Certificate.getInstance() is failing with:
Caused by: javax.net.ssl.SSLPeerUnverifiedException: Could not find class: java.lang.ClassNotFoundException: com/sun/security/cert/internal/x509/X509V1CertImpl
We should be instantiating X509Certificates through the CertificateFactory and use the legacy classes only in the deprecated public javax.security.cert.X509Certificate[] getPeerCertificateChain() throws SSLPeerUnverifiedException