Package org.ldaptive.ssl
Class AllowAnyHostnameVerifier
- java.lang.Object
-
- org.ldaptive.ssl.AllowAnyHostnameVerifier
-
- All Implemented Interfaces:
javax.net.ssl.HostnameVerifier
,CertificateHostnameVerifier
public class AllowAnyHostnameVerifier extends java.lang.Object implements javax.net.ssl.HostnameVerifier, CertificateHostnameVerifier
Hostname verifier that returns true for any hostname. Use with caution.- Author:
- Middleware Services
-
-
Constructor Summary
Constructors Constructor Description AllowAnyHostnameVerifier()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
verify(java.lang.String hostname, java.security.cert.X509Certificate cert)
Verify the supplied hostname matches the supplied certificate.boolean
verify(java.lang.String hostname, javax.net.ssl.SSLSession session)
-
-
-
Method Detail
-
verify
public boolean verify(java.lang.String hostname, javax.net.ssl.SSLSession session)
- Specified by:
verify
in interfacejavax.net.ssl.HostnameVerifier
-
verify
public boolean verify(java.lang.String hostname, java.security.cert.X509Certificate cert)
Description copied from interface:CertificateHostnameVerifier
Verify the supplied hostname matches the supplied certificate.- Specified by:
verify
in interfaceCertificateHostnameVerifier
- Parameters:
hostname
- to verifycert
- to verify hostname against- Returns:
- whether hostname is valid for the supplied certificate
-
-