-
public abstract class CertificateChainCleanerComputes the effective certificate chain from the raw array returned by Java's built in TLS APIs. Cleaning a chain returns a list of certificates where the first element is
{@code chain[0]}, each certificate is signed by the certificate that follows, and the last certificate is a trusted CA certificate.Use of the chain cleaner is necessary to omit unexpected certificates that aren't relevant to the TLS handshake and to extract the trusted CA certificate for the benefit of certificate pinning.
-
-
Method Summary
Modifier and Type Method Description abstract List<Certificate>clean(List<Certificate> chain, String hostname)static CertificateChainCleanerget(X509TrustManager trustManager)static CertificateChainCleanerget(Array<X509Certificate> caCerts)-
-
Method Detail
-
clean
abstract List<Certificate> clean(List<Certificate> chain, String hostname)
-
get
static CertificateChainCleaner get(X509TrustManager trustManager)
-
get
static CertificateChainCleaner get(Array<X509Certificate> caCerts)
-
-
-
-