Code example for BrowserCompatHostnameVerifier

0
import org.apache.http.params.HttpParams; 
 
public class SSLSocketFactory implements LayeredSocketFactory {
 
   public static final X509HostnameVerifier ALLOW_ALL_HOSTNAME_VERIFIER = new AllowAllHostnameVerifier();
   public static final X509HostnameVerifier BROWSER_COMPATIBLE_HOSTNAME_VERIFIER = new BrowserCompatHostnameVerifier();
   private static final SSLSocketFactory DEFAULT_FACTORY = new SSLSocketFactory();
   public static final String SSL = "SSL";
   public static final String SSLV2 = "SSLv2";
   public static final X509HostnameVerifier STRICT_HOSTNAME_VERIFIER = new StrictHostnameVerifier();
   public static final String TLS = "TLS";
   private X509HostnameVerifier hostnameVerifier;
   private final HostNameResolver nameResolver;
   private final javax.net.ssl.SSLSocketFactory socketfactory;
   private final SSLContext sslcontext;
 
 
   private SSLSocketFactory() { 
      X509HostnameVerifier var1 = BROWSER_COMPATIBLE_HOSTNAME_VERIFIER;
      this.hostnameVerifier = var1;
      this.sslcontext = null;