-
public final class BasicCertificateChainCleaner extends CertificateChainCleaner
A certificate chain cleaner that uses a set of trusted root certificates to build the trusted chain. This class duplicates the clean chain building performed during the TLS handshake. We prefer other mechanisms where they exist, such as with
{@code okhttp3.internal.platform.AndroidPlatform.AndroidCertificateChainCleaner}.This class includes code from Conscrypt's
{@code * TrustManagerImpl}and{@code TrustedCertificateIndex}.
-
-
Constructor Summary
Constructors Constructor Description BasicCertificateChainCleaner(TrustRootIndex trustRootIndex)
-
Method Summary
Modifier and Type Method Description List<Certificate>clean(List<Certificate> chain, String hostname)Returns a cleaned chain for {@code chain}.inthashCode()booleanequals(Object other)-
-
Constructor Detail
-
BasicCertificateChainCleaner
BasicCertificateChainCleaner(TrustRootIndex trustRootIndex)
-
-
Method Detail
-
clean
List<Certificate> clean(List<Certificate> chain, String hostname)
Returns a cleaned chain for
{@code chain}.This method throws if the complete chain to a trusted CA certificate cannot be constructed.This is unexpected unless the trust root index in this class has a different trust manager thanwhat was used to establish
{@code chain}.
-
hashCode
int hashCode()
-
-
-
-