Package org.miaixz.bus.http.secure
Class BasicCertificateChainCleaner
java.lang.Object
org.miaixz.bus.http.secure.CertificateChainCleaner
org.miaixz.bus.http.secure.BasicCertificateChainCleaner
使用一组可信根证书来构建可信链的证书链清理器。
这个类复制了在TLS握手期间执行的clean chain构建。我们更喜欢它们
存在的其他机制,比如
AndroidCertificateChainCleaner- Since:
- Java 17+
- Author:
- Kimi Liu
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclean(List<Certificate> chain, String hostname) Returns a cleaned chain forchain.booleaninthashCode()Methods inherited from class org.miaixz.bus.http.secure.CertificateChainCleaner
get, get
-
Constructor Details
-
BasicCertificateChainCleaner
-
-
Method Details
-
clean
public List<Certificate> clean(List<Certificate> chain, String hostname) throws SSLPeerUnverifiedException Returns a cleaned chain forchain. 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 than what was used to establishchain.- Specified by:
cleanin classCertificateChainCleaner- Throws:
SSLPeerUnverifiedException
-
hashCode
public int hashCode() -
equals
-