Package org.apache.http.conn.ssl
Interface X509HostnameVerifier
-
- All Superinterfaces:
javax.net.ssl.HostnameVerifier
- All Known Implementing Classes:
AbstractVerifier
,AllowAllHostnameVerifier
,BrowserCompatHostnameVerifier
,StrictHostnameVerifier
@Deprecated public interface X509HostnameVerifier extends javax.net.ssl.HostnameVerifier
Deprecated.(4.4) UseHostnameVerifier
.Interface for checking if a hostname matches the names stored inside the server's X.509 certificate. This interface extendsHostnameVerifier
, but it is recommended to use methods added by X509HostnameVerifier.- Since:
- 4.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description void
verify(java.lang.String host, java.lang.String[] cns, java.lang.String[] subjectAlts)
Deprecated.Checks to see if the supplied hostname matches any of the supplied CNs or "DNS" Subject-Alts.void
verify(java.lang.String host, java.security.cert.X509Certificate cert)
Deprecated.Verifies that the host name is an acceptable match with the server's authentication scheme based on the givenX509Certificate
.void
verify(java.lang.String host, javax.net.ssl.SSLSocket ssl)
Deprecated.Verifies that the host name is an acceptable match with the server's authentication scheme based on the givenSSLSocket
.
-
-
-
Method Detail
-
verify
void verify(java.lang.String host, javax.net.ssl.SSLSocket ssl) throws java.io.IOException
Deprecated.Verifies that the host name is an acceptable match with the server's authentication scheme based on the givenSSLSocket
.- Parameters:
host
- the host.ssl
- the SSL socket.- Throws:
java.io.IOException
- if an I/O error occurs or the verification process fails.
-
verify
void verify(java.lang.String host, java.security.cert.X509Certificate cert) throws javax.net.ssl.SSLException
Deprecated.Verifies that the host name is an acceptable match with the server's authentication scheme based on the givenX509Certificate
.- Parameters:
host
- the host.cert
- the certificate.- Throws:
javax.net.ssl.SSLException
- if the verification process fails.
-
verify
void verify(java.lang.String host, java.lang.String[] cns, java.lang.String[] subjectAlts) throws javax.net.ssl.SSLException
Deprecated.Checks to see if the supplied hostname matches any of the supplied CNs or "DNS" Subject-Alts. Most implementations only look at the first CN, and ignore any additional CNs. Most implementations do look at all of the "DNS" Subject-Alts. The CNs or Subject-Alts may contain wildcards according to RFC 2818.- Parameters:
cns
- CN fields, in order, as extracted from the X.509 certificate.subjectAlts
- Subject-Alt fields of type 2 ("DNS"), as extracted from the X.509 certificate.host
- The hostname to verify.- Throws:
javax.net.ssl.SSLException
- if the verification process fails.
-
-