public class CertificateUtil extends Object
Constructor and Description |
---|
CertificateUtil() |
Modifier and Type | Method and Description |
---|---|
static Set<TrustAnchor> |
getDefaultRootCAs()
Obtains the list of default root CAs installed in the JRE.
|
static X509TrustManager |
getDefaultX509TrustManager()
Loads the system default
X509TrustManager . |
static PKIXCertPathValidatorResult |
validatePath(List<X509Certificate> certs)
Validate a certificate chain.
|
static PKIXCertPathValidatorResult |
validatePath(List<X509Certificate> certs,
Set<TrustAnchor> trustAnchors) |
public static Set<TrustAnchor> getDefaultRootCAs() throws NoSuchAlgorithmException, KeyStoreException
public static X509TrustManager getDefaultX509TrustManager() throws NoSuchAlgorithmException, KeyStoreException
X509TrustManager
.public static PKIXCertPathValidatorResult validatePath(List<X509Certificate> certs) throws GeneralSecurityException
GeneralSecurityException
public static PKIXCertPathValidatorResult validatePath(List<X509Certificate> certs, Set<TrustAnchor> trustAnchors) throws GeneralSecurityException
GeneralSecurityException
Copyright © 2019. All rights reserved.