linguokun
linguokun

Reputation: 41

Android SSLProtocolException and unexpected end of stream on Connection on OkHttp

There is very low probability to produce "HTTP FAILED: javax.net.ssl.SSLProtocolException: Read error: ssl=0xdfa6e140: Failure in SSL library, usually a protocol error error:100000d7:SSL routines:OPENSSL_internal:SSL_HANDSHAKE_FAILURE (external/boringssl/src/ssl/ssl_lib.c:710 0xe57a3144:0x00000000)" and "unexpected end of stream on Connection{xmart.xiaopeng.com:443, proxy=DIRECT hostAddress=xmart.xiaopeng.com/118.31.212.217:443 cipherSuite=TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 protocol=http/1.1}".

Upvotes: 1

Views: 553

Answers (1)

linguokun
linguokun

Reputation: 41

Our company's certificate is saved at the android assets folder and we will validate it with server's. So I think as you said, our company just want to work with our company's certificate rather than other additional certificates.

So How can I avoid this similar exception? These SSLProtocolExceptions will happen at very low probability.(not 100% happen, the happen probability maybe 1%)

I search this SSLProtocolException with "error:100000d7" in Google and Baidu. there are very few people encounter these similar exceptions(because the error code is error:100000d7, this error code is very few in the google search).

Upvotes: 1

Related Questions