Skip to content

Commit

Permalink
ApacheHTTP enforce TLS1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
scribe committed Mar 15, 2023
1 parent 3347eb3 commit 9f39ebe
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ private static CloseableHttpClient createInsecureSslHttpClient() throws NoSuchAl
final SSLContext sslContext = new SSLContextBuilder()
.setProtocol(INSECURE_SSL_PROTOCOL)
.loadTrustMaterial(null, (TrustStrategy) (chain, authType) -> true).build();
final SSLConnectionSocketFactory sslsf = new SSLConnectionSocketFactory(sslContext, new NoopHostnameVerifier());
final SSLConnectionSocketFactory sslsf = new SSLConnectionSocketFactory(sslContext, new String[]{ INSECURE_SSL_PROTOCOL }, null, new NoopHostnameVerifier());

final Registry<ConnectionSocketFactory> socketFactoryRegistry = RegistryBuilder.<ConnectionSocketFactory>create()
.register("http", PlainConnectionSocketFactory.getSocketFactory())
Expand Down

0 comments on commit 9f39ebe

Please sign in to comment.