|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.http.conn.ssl.AbstractVerifier
org.apache.http.conn.ssl.BrowserCompatHostnameVerifier
public class BrowserCompatHostnameVerifier
The HostnameVerifier that works the same way as Curl and Firefox.
The hostname must match either the first CN, or any of the subject-alts. A wildcard can occur in the CN, and in any of the subject-alts. The only difference between BROWSER_COMPATIBLE and STRICT is that a wildcard (such as "*.foo.com") with BROWSER_COMPATIBLE matches all subdomains, including "a.b.foo.com".
| Constructor Summary | |
|---|---|
BrowserCompatHostnameVerifier()
|
|
| Method Summary | |
|---|---|
java.lang.String |
toString()
|
void |
verify(java.lang.String host,
java.lang.String[] cns,
java.lang.String[] subjectAlts)
Checks to see if the supplied hostname matches any of the supplied CNs or "DNS" Subject-Alts. |
| Methods inherited from class org.apache.http.conn.ssl.AbstractVerifier |
|---|
acceptableCountryWildcard, countDots, getCNs, getDNSSubjectAlts, verify, verify, verify, verify |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public BrowserCompatHostnameVerifier()
| Method Detail |
|---|
public final void verify(java.lang.String host,
java.lang.String[] cns,
java.lang.String[] subjectAlts)
throws javax.net.ssl.SSLException
X509HostnameVerifier
host - The hostname to verify.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.
javax.net.ssl.SSLException - If verification failed.public final java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||