@Contract(threading=STATELESS) public final class DefaultHostnameVerifier extends Object implements HttpClientHostnameVerifier
HostnameVerifier
implementation.Constructor and Description |
---|
DefaultHostnameVerifier() |
DefaultHostnameVerifier(PublicSuffixMatcher publicSuffixMatcher) |
Modifier and Type | Method and Description |
---|---|
boolean |
verify(String host,
javax.net.ssl.SSLSession session) |
void |
verify(String host,
X509Certificate cert)
Verifies the supplied server
X509Certificate and ensures it matches
the original host name. |
public DefaultHostnameVerifier()
public DefaultHostnameVerifier(PublicSuffixMatcher publicSuffixMatcher)
public boolean verify(String host, javax.net.ssl.SSLSession session)
verify
in interface javax.net.ssl.HostnameVerifier
public void verify(String host, X509Certificate cert) throws SSLException
HttpClientHostnameVerifier
X509Certificate
and ensures it matches
the original host name.verify
in interface HttpClientHostnameVerifier
host
- the original host name.cert
- the server certificate;SSLException