简体   繁体   中英

how to get the Root certificates and intermediate certificates for android SSL

我需要为我当前在http上运行的android应用程序实施安全措施,我正在ssl上阅读,发现我们需要根证书和中间证书,如果我不从外部购买证书,我该如何获得根证书和中间证书。 。 谢谢

Do you mean you will be using a self signed or self issued certificate on the public facing server? (Neither of which I would recommend)

If you really want to try and do that then:

  • a self signed certificate sign's itself (it is its own CA)
  • a self issued certificate on windows for example use the mmc certificates tool, you can download the public part of any certificates in the trust chain (but then you'd need to get them on to a device for them to be useful and something owners of the devices would not like since I would bet you do not have proper key management in place).

A potentially better way would be to use a properly issued certificate for your production site which would allow you to validate the hostname and trust chain correctly.

But for your local dev builds have it ignore these two checks (I would also have it put up a Toast if it was running in this mode so you don't issue this by mistake).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM