September 15, 2016

Difference between java.security.cert.X509Certificate and javax.security.cert.X509Certificate

java.security.cert.X509Certificate

java.security.cert.X509Certificate supports all X.509 certificate versions (v1, v2 and v3).

https://docs.oracle.com/javase/8/docs/api/java/security/cert/X509Certificate.html

javax.security.cert.X509Certificate 

javax.security.cert.X509Certificate only supports v1.

https://docs.oracle.com/javase/8/docs/api/index.html?javax/security/cert/X509Certificate.html

Conclusion

Always use java.security.cert.X509Certificate.

No comments: