Hakan Altindag created HTTPCLIENT-2311:
------------------------------------------
Summary: Http Client not working anymore with SSL configuration
Key: HTTPCLIENT-2311
URL: https://issues.apache.org/jira/browse/HTTPCLIENT-2311
Project: HttpComponents HttpClient
Issue Type: Bug
Affects Versions: 5.2.2
Reporter: Hakan Altindag
Fix For: 5.2.1
The Apache Http Client in version 5.2.2 stopped working. It fails to initialize
because it tries to use a proxy while it is not specified. It was working until
version 5.2.1 but now it fails.
The stacktrace:
{code:java}
java.lang.IllegalArgumentException: Invalid Proxy
at java.base/java.net.Socket.<init>(Socket.java:177) at
[email protected]/org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.createSocket(SSLConnectionSocketFactory.java:208)
at
[email protected]/org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:158)
at
[email protected]/org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:447)
at
[email protected]/org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:162)
at
[email protected]/org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:172)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ConnectExec.execute(ConnectExec.java:142)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ProtocolExec.execute(ProtocolExec.java:192)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51)
at
[email protected]/org.apache.hc.client5.http.impl.classic.HttpRequestRetryExec.execute(HttpRequestRetryExec.java:96)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ContentCompressionExec.execute(ContentCompressionExec.java:152)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51)
at
[email protected]/org.apache.hc.client5.http.impl.classic.RedirectExec.execute(RedirectExec.java:115)
at
[email protected]/org.apache.hc.client5.http.impl.classic.ExecChainElement.execute(ExecChainElement.java:51)
at
[email protected]/org.apache.hc.client5.http.impl.classic.InternalHttpClient.doExecute(InternalHttpClient.java:170)
at
[email protected]/org.apache.hc.client5.http.impl.classic.CloseableHttpClient.execute(CloseableHttpClient.java:123)
at
[email protected]/org.apache.hc.client5.http.impl.classic.CloseableHttpClient.execute(CloseableHttpClient.java:55)
at
nl.altindag.ssl.apache5/nl.altindag.ssl.apache5.SSLFactoryIT.executeHttpsRequestWithMutualAuthentication(SSLFactoryIT.java:89)
at java.base/java.lang.reflect.Method.invoke(Method.java:568) at
java.base/java.util.ArrayList.forEach(ArrayList.java:1511) at
java.base/java.util.ArrayList.forEach(ArrayList.java:1511) {code}
The failing build pipeline:
[https://github.com/Hakky54/sslcontext-kickstart/pull/414]
The failing integration test:
[https://github.com/Hakky54/sslcontext-kickstart/blob/da231f1c5a849c8e80f0367fe780c495b428cb62/sslcontext-kickstart-for-apache5/src/test/java/nl/altindag/ssl/apache5/SSLFactoryIT.java#L73]
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]