问题
currently my app connects to a (special) webserver via HTTP to retrieve some data from there via GET/POST and HttpClient.
Now I plan to switch over to HTTPS. My problem: the webpage I'm communicating with uses a CACert root certificate which is not available on all Android devices, so for most users this connection will fail.
CACert provides their root certificates at http://www.cacert.org/index.php?id=3&lang=en . Is there a possibility to use these certificates for my HTTPS connection? I don't expect to install it silently for the whole system, for me it would be enough to provide it just for my special HttpClient connection.
Thanks!
回答1:
OK, found a solution including code example here: http://developer.android.com/training/articles/security-ssl.html
来源:https://stackoverflow.com/questions/22217513/provide-own-root-certificate-for-https-connection