I have a very specific SSL issue on my Android. If I try to visit a particular website via code, I get the following error:
SSL handshake failure: Failure in SSL library, usually a protocol error
error:140773F2:SSL routines:SSL23_GET_SERVER_HELLO: sslv3 alert unexpected message (external/openssl/ssl/s23_cInt.c:500 0xaf076228:0x00000000)
I get this regardless of the build… I’ve tried it on API levels 1.5, 1.6, 2.2, and 4.0 and gotten the same result each time.
After some troubleshooting I tried to visit the website through a browser and I got the following error:
Data connectivity problem
A secure connection could not be established.
Here’s the thing, though… the website opens just fine on Windows browsers (tested on Firefox, IE, and Chrome). It also opens just fine on iOS devices which uses the same webkit as the Android, which is odd. The website also works without problems on the Opera Mini browser.
I’ve tried workarounds by adding the client certificate to the keystore and by ignoring invalid client certificates, with no results. However it appears that the certificate itself is not the issue.
I’m at an impasse. Can anybody provide any guidance on how I can get this to work?
How are you accessing this site? Through the Android browser? WebView? Or HttpClient/HTTPSURLConnection? It seems it only responds to SSL3, you have to force your client to use it.