java add self signed certificate to keystore programatically

血红的双手。 提交于 2019-12-22 18:20:48

问题


I added the self signed certificate using keystore from command prompt.

I found several links which tells how to add certificate to keystore, but they all say to store the certificate locally before running program and do the rest via code. I need to add certificate to keystore dynamically.

How can I add a certificate programatically?


回答1:


You can refer this blog for more help

The JDK JavaDoc for java.security.KeyStore is pretty useful too.

If you want to import from external server refer the sun implementation



来源:https://stackoverflow.com/questions/19628753/java-add-self-signed-certificate-to-keystore-programatically

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!