javax.net.ssl.SSLHandshakeException: Connection closed by peer

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • GitHub comment 67#241623085
    via GitHub by obilodeau
    ,
  • GitHub comment 67#241623083
    via GitHub by obilodeau
    ,
  • h6.Issue Description Today now that Google released what should be the final builds of Android L we upgraded our Nexus 5 device to it from the Google Page: http://developer.android.com/preview/index.html I just loaded this in the iPhone Sim and I got the success alert as expected. I tried it on the Android Phone running 4.2.2 and it also got the success alert. On the Nexus 5 running Android 5.0 I get an error alert with this error in the logs attached. h6.Sample code {code} var url = "https_url"; var xhr = Ti.Network.createHTTPClient({ onload: function(e) { Ti.API.debug(this.responseText); alert('success'); }, onerror: function(e) { Ti.API.debug(e.error); alert('error'); }, timeout:5000 /* in milliseconds */ }); xhr.open("GET", url); xhr.send(); {code} h6.Logs {code} 10-20 13:05:18.293: D/Window(27268): Checkpoint: postWindowCreated() 10-20 13:05:18.296: E/TiHttpClient(27268): (TiHttpClient-1) [143,143] HTTP Error (javax.net.ssl.SSLHandshakeException): Connection closed by peer 10-20 13:05:18.296: E/TiHttpClient(27268): javax.net.ssl.SSLHandshakeException: Connection closed by peer 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.NativeCrypto.SSL_do_handshake(Native Method) 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:302) 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.OpenSSLSocketImpl.waitForHandshake(OpenSSLSocketImpl.java:598) 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.OpenSSLSocketImpl.getInputStream(OpenSSLSocketImpl.java:560) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.io.SocketInputBuffer.<init>(SocketInputBuffer.java:70) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.SocketHttpClientConnection.createSessionInputBuffer(SocketHttpClientConnection.java:83) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.DefaultClientConnection.createSessionInputBuffer(DefaultClientConnection.java:170) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.SocketHttpClientConnection.bind(SocketHttpClientConnection.java:106) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.DefaultClientConnection.openCompleted(DefaultClientConnection.java:129) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:172) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:164) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:119) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:360) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:555) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:653) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:637) 10-20 13:05:18.296: E/TiHttpClient(27268): at ti.modules.titanium.network.TiHTTPClient$ClientRunnable.run(TiHTTPClient.java:1328) 10-20 13:05:18.296: E/TiHttpClient(27268): at java.lang.Thread.run(Thread.java:818) 10-20 13:05:18.311: D/TiAPI(27268): Connection closed by peer {code} h6.Tiapp.xml http://docs.appcelerator.com/titanium/3.0/#!/guide/Installing_the_Android_SDK-section-29004851_InstallingtheAndroidSDK-SupportforAndroidWearandAndroidLSDKs
    via by Eduardo Gomez,
  • h6.Issue Description Today now that Google released what should be the final builds of Android L we upgraded our Nexus 5 device to it from the Google Page: http://developer.android.com/preview/index.html I just loaded this in the iPhone Sim and I got the success alert as expected. I tried it on the Android Phone running 4.2.2 and it also got the success alert. On the Nexus 5 running Android 5.0 I get an error alert with this error in the logs attached. h6.Sample code {code} var url = "https_url"; var xhr = Ti.Network.createHTTPClient({ onload: function(e) { Ti.API.debug(this.responseText); alert('success'); }, onerror: function(e) { Ti.API.debug(e.error); alert('error'); }, timeout:5000 /* in milliseconds */ }); xhr.open("GET", url); xhr.send(); {code} h6.Logs {code} 10-20 13:05:18.293: D/Window(27268): Checkpoint: postWindowCreated() 10-20 13:05:18.296: E/TiHttpClient(27268): (TiHttpClient-1) [143,143] HTTP Error (javax.net.ssl.SSLHandshakeException): Connection closed by peer 10-20 13:05:18.296: E/TiHttpClient(27268): javax.net.ssl.SSLHandshakeException: Connection closed by peer 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.NativeCrypto.SSL_do_handshake(Native Method) 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:302) 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.OpenSSLSocketImpl.waitForHandshake(OpenSSLSocketImpl.java:598) 10-20 13:05:18.296: E/TiHttpClient(27268): at com.android.org.conscrypt.OpenSSLSocketImpl.getInputStream(OpenSSLSocketImpl.java:560) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.io.SocketInputBuffer.<init>(SocketInputBuffer.java:70) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.SocketHttpClientConnection.createSessionInputBuffer(SocketHttpClientConnection.java:83) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.DefaultClientConnection.createSessionInputBuffer(DefaultClientConnection.java:170) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.SocketHttpClientConnection.bind(SocketHttpClientConnection.java:106) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.DefaultClientConnection.openCompleted(DefaultClientConnection.java:129) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:172) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:164) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:119) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:360) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:555) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:653) 10-20 13:05:18.296: E/TiHttpClient(27268): at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:637) 10-20 13:05:18.296: E/TiHttpClient(27268): at ti.modules.titanium.network.TiHTTPClient$ClientRunnable.run(TiHTTPClient.java:1328) 10-20 13:05:18.296: E/TiHttpClient(27268): at java.lang.Thread.run(Thread.java:818) 10-20 13:05:18.311: D/TiAPI(27268): Connection closed by peer {code} h6.Tiapp.xml http://docs.appcelerator.com/titanium/3.0/#!/guide/Installing_the_Android_SDK-section-29004851_InstallingtheAndroidSDK-SupportforAndroidWearandAndroidLSDKs
    via by Eduardo Gomez,
  • GitHub comment 9#220905431
    via GitHub by ukotdiya01
    ,
    • javax.net.ssl.SSLHandshakeException: Connection closed by peer at com.android.org.conscrypt.NativeCrypto.SSL_do_handshake(Native Method) at com.android.org.conscrypt.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:302) at com.android.org.conscrypt.OpenSSLSocketImpl.waitForHandshake(OpenSSLSocketImpl.java:598) at com.android.org.conscrypt.OpenSSLSocketImpl.getInputStream(OpenSSLSocketImpl.java:560) at org.apache.http.impl.io.SocketInputBuffer.<init>(SocketInputBuffer.java:70) at org.apache.http.impl.SocketHttpClientConnection.createSessionInputBuffer(SocketHttpClientConnection.java:83) at org.apache.http.impl.conn.DefaultClientConnection.createSessionInputBuffer(DefaultClientConnection.java:170) at org.apache.http.impl.SocketHttpClientConnection.bind(SocketHttpClientConnection.java:106) at org.apache.http.impl.conn.DefaultClientConnection.openCompleted(DefaultClientConnection.java:129) at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:172) at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:164) at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:119) at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:360) at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:555) at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:487) at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:465) at org.tomdroid.sync.web.WebConnection.execute(WebConnection.java:124) at org.tomdroid.sync.web.AnonymousConnection.get(AnonymousConnection.java:42) at org.tomdroid.sync.web.OAuthConnection.getAuthorizationUrl(OAuthConnection.java:131) at org.tomdroid.sync.web.SnowySyncService$1.run(SnowySyncService.java:102) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) at java.lang.Thread.run(Thread.java:818)

    Users with the same issue

    Unknown visitor1 times, last one,
    gamebusterz
    gamebusterz1 times, last one,
    Unknown visitor1 times, last one,
    Unknown visitor1 times, last one,
    Agócs Tamás
    Agócs Tamás33 times, last one,
    27 more bugmates