Created
November 12, 2013 08:34
-
-
Save nisshiee/7427533 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SSLSocketFactory sslsf = new SSLSocketFactory(new TrustStrategy() { | |
@Override | |
public boolean isTrusted(X509Certificate[] chain, String authType) throws CertificateException { | |
return true; | |
} | |
}, SSLSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER); | |
HttpClient cli = new DefaultHttpClient(); | |
cli.getConnectionManager().getSchemeRegistry().register(new Scheme("https", 443, sslsf)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment