|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.http.conn.ssl.TrustSelfSignedStrategy
public class TrustSelfSignedStrategy
A trust strategy that accepts self-signed certificates as trusted. Verification of all other certificates is done by the trust manager configured in the SSL context.
Constructor Summary | |
---|---|
TrustSelfSignedStrategy()
|
Method Summary | |
---|---|
boolean |
isTrusted(java.security.cert.X509Certificate[] chain,
java.lang.String authType)
Determines whether the certificate chain can be trusted without consulting the trust manager configured in the actual SSL context. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TrustSelfSignedStrategy()
Method Detail |
---|
public boolean isTrusted(java.security.cert.X509Certificate[] chain, java.lang.String authType) throws java.security.cert.CertificateException
TrustStrategy
Please note that, if this method returns false
, the trust manager configured
in the actual SSL context can still clear the certificate as trusted.
isTrusted
in interface TrustStrategy
chain
- the peer certificate chainauthType
- the authentication type based on the client certificate
true
if the certificate can be trusted without verification by
the trust manager, false
otherwise.
java.security.cert.CertificateException
- thrown if the certificate is not trusted or invalid.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |