You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Andrew Parks (Jira)" <ji...@apache.org> on 2020/02/07 05:15:00 UTC

[jira] [Updated] (HTTPCLIENT-2050) Conscrypt fails with "Socket is closed" exception with HttpClient 5.0-beta7

     [ https://issues.apache.org/jira/browse/HTTPCLIENT-2050?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Parks updated HTTPCLIENT-2050:
-------------------------------------
    Description: 
Test case attached, which attempts to use HttpClient to connect to [https://www.wikipedia.org/] both with and without Conscrypt. 

The following error appears only when using Conscrypt:

{{{{Exception in thread "main" java.net.SocketException: Socket is closed}}}}
{{ \{{ at org.conscrypt.NativeSsl.doHandshake(NativeSsl.java:384)}}}}
{{ \{{ at org.conscrypt.ConscryptFileDescriptorSocket.startHandshake(ConscryptFileDescriptorSocket.java:225)}}}}
{{ \{{ at org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:276)}}}}
{{ \{{ at org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:244)}}}}
{{ \{{ at org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:148)}}}}
{{ \{{ at org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:409)}}}}
{{ \{{ at org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:164)}}}}
{{ \{{ at org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:174)}}}}
{{ \{{ at org.apache.hc.client5.http.impl.classic.ConnectExec.execute(ConnectExec.java:135)}}}}

To replicate this, please put the attached get-dependencies-compile-run.sh, Test.java and log4j2.xml files into an empty directory. Then run get-dependencies-compile-run.sh, which will download the necessary jars, compile the Java code, and run it.

The full debug output when tested on Linux and MacOS are contained in the linux.txt and macos.txt files attached.

 

  was:
Test case attached, which attempts to use HttpClient to connect to [https://www.wikipedia.org/] both with and without Conscrypt. 

The following error appears only when using Conscrypt:

{{Exception in thread "main" java.net.SocketException: Socket is closed}}
{{ at org.conscrypt.NativeSsl.doHandshake(NativeSsl.java:384)}}
{{ at org.conscrypt.ConscryptFileDescriptorSocket.startHandshake(ConscryptFileDescriptorSocket.java:225)}}
{{ at org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:276)}}
{{ at org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:244)}}
{{ at org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:148)}}
{{ at org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:409)}}
{{ at org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:164)}}
{{ at org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:174)}}
{{ at org.apache.hc.client5.http.impl.classic.ConnectExec.execute(ConnectExec.java:135)}}

To replicate this, please put the attached get-dependencies-compile-run.sh, Test.java and log4j2.xml files into an empty directory. Then run get-dependencies-compile-run.sh, which will download the necessary jars, compile the Java code, and run it.

The full debug output when tested on Linux and MacOS are contained in the linux.txt and macos.txt files attached.

 


> Conscrypt fails with "Socket is closed" exception with HttpClient 5.0-beta7
> ---------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-2050
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-2050
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient (classic)
>    Affects Versions: 5.0 Beta7
>         Environment: Tested on both MacOS 10.15.2 and on CentOS 7.7 (on completely different machines).
>            Reporter: Andrew Parks
>            Priority: Major
>              Labels: conscrypt
>         Attachments: Test.java, get-dependencies-compile-run.sh, linux.txt, log4j2.xml, macos.txt
>
>
> Test case attached, which attempts to use HttpClient to connect to [https://www.wikipedia.org/] both with and without Conscrypt. 
> The following error appears only when using Conscrypt:
> {{{{Exception in thread "main" java.net.SocketException: Socket is closed}}}}
> {{ \{{ at org.conscrypt.NativeSsl.doHandshake(NativeSsl.java:384)}}}}
> {{ \{{ at org.conscrypt.ConscryptFileDescriptorSocket.startHandshake(ConscryptFileDescriptorSocket.java:225)}}}}
> {{ \{{ at org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:276)}}}}
> {{ \{{ at org.apache.hc.client5.http.ssl.SSLConnectionSocketFactory.connectSocket(SSLConnectionSocketFactory.java:244)}}}}
> {{ \{{ at org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.connect(DefaultHttpClientConnectionOperator.java:148)}}}}
> {{ \{{ at org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.connect(PoolingHttpClientConnectionManager.java:409)}}}}
> {{ \{{ at org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:164)}}}}
> {{ \{{ at org.apache.hc.client5.http.impl.classic.InternalExecRuntime.connectEndpoint(InternalExecRuntime.java:174)}}}}
> {{ \{{ at org.apache.hc.client5.http.impl.classic.ConnectExec.execute(ConnectExec.java:135)}}}}
> To replicate this, please put the attached get-dependencies-compile-run.sh, Test.java and log4j2.xml files into an empty directory. Then run get-dependencies-compile-run.sh, which will download the necessary jars, compile the Java code, and run it.
> The full debug output when tested on Linux and MacOS are contained in the linux.txt and macos.txt files attached.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org