@Contract(threading=IMMUTABLE_CONDITIONAL) public final class DefaultHostnameVerifier extends Object implements HostnameVerifier
HostnameVerifier
implementation.Modifier and Type | Class and Description |
---|---|
(package private) static class |
DefaultHostnameVerifier.HostNameType |
Modifier and Type | Field and Description |
---|---|
private org.apache.commons.logging.Log |
log |
private PublicSuffixMatcher |
publicSuffixMatcher |
Constructor and Description |
---|
DefaultHostnameVerifier() |
DefaultHostnameVerifier(PublicSuffixMatcher publicSuffixMatcher) |
Modifier and Type | Method and Description |
---|---|
(package private) static DefaultHostnameVerifier.HostNameType |
determineHostFormat(String host) |
(package private) static String |
extractCN(String subjectPrincipal) |
(package private) static List<SubjectName> |
getSubjectAltNames(X509Certificate cert) |
(package private) static void |
matchCN(String host,
String cn,
PublicSuffixMatcher publicSuffixMatcher) |
(package private) static void |
matchDNSName(String host,
List<SubjectName> subjectAlts,
PublicSuffixMatcher publicSuffixMatcher) |
(package private) static boolean |
matchDomainRoot(String host,
String domainRoot) |
(package private) static boolean |
matchIdentity(String host,
String identity) |
(package private) static boolean |
matchIdentity(String host,
String identity,
PublicSuffixMatcher publicSuffixMatcher) |
private static boolean |
matchIdentity(String host,
String identity,
PublicSuffixMatcher publicSuffixMatcher,
boolean strict) |
(package private) static boolean |
matchIdentityStrict(String host,
String identity) |
(package private) static boolean |
matchIdentityStrict(String host,
String identity,
PublicSuffixMatcher publicSuffixMatcher) |
(package private) static void |
matchIPAddress(String host,
List<SubjectName> subjectAlts) |
(package private) static void |
matchIPv6Address(String host,
List<SubjectName> subjectAlts) |
(package private) static String |
normaliseAddress(String hostname) |
boolean |
verify(String host,
SSLSession session) |
void |
verify(String host,
X509Certificate cert) |
private final org.apache.commons.logging.Log log
private final PublicSuffixMatcher publicSuffixMatcher
public DefaultHostnameVerifier(PublicSuffixMatcher publicSuffixMatcher)
public DefaultHostnameVerifier()
public boolean verify(String host, SSLSession session)
verify
in interface HostnameVerifier
public void verify(String host, X509Certificate cert) throws SSLException
SSLException
static void matchIPAddress(String host, List<SubjectName> subjectAlts) throws SSLException
SSLException
static void matchIPv6Address(String host, List<SubjectName> subjectAlts) throws SSLException
SSLException
static void matchDNSName(String host, List<SubjectName> subjectAlts, PublicSuffixMatcher publicSuffixMatcher) throws SSLException
SSLException
static void matchCN(String host, String cn, PublicSuffixMatcher publicSuffixMatcher) throws SSLException
SSLException
static boolean matchDomainRoot(String host, String domainRoot)
private static boolean matchIdentity(String host, String identity, PublicSuffixMatcher publicSuffixMatcher, boolean strict)
static boolean matchIdentity(String host, String identity, PublicSuffixMatcher publicSuffixMatcher)
static boolean matchIdentity(String host, String identity)
static boolean matchIdentityStrict(String host, String identity, PublicSuffixMatcher publicSuffixMatcher)
static boolean matchIdentityStrict(String host, String identity)
static String extractCN(String subjectPrincipal) throws SSLException
SSLException
static DefaultHostnameVerifier.HostNameType determineHostFormat(String host)
static List<SubjectName> getSubjectAltNames(X509Certificate cert)
static String normaliseAddress(String hostname)
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses