售前咨询
技术支持
渠道合作

常见问题: 如何使用keystore.jks转换为apache、nginx使用的key和crt文件?

您好!您可按以下命令转换:

1、从JKS转换到PKCS12keytool

-importkeystore -srckeystore D:\keystore.jks -destkeystore D:\keystore.p12 -srcstoretype JKS -deststoretype PKCS12 -srcstorepass 123456 -deststorepass 123456 -srcalias testweb -destalias testweb -srckeypass 123456 -destkeypass 123456 –noprompt

2、从PKCS12转换成PEM格式 openssl pkcs12

-in D:\keystore.p12 -out D:\testweb.gdca.com.cn.cn.pem -passin pass:123456 -passout pass:123456

3、用记事本打开PEM格式文件,将“—–BEGIN ENCRYPTED PRIVATE KEY—–”至“—–END ENCRYPTED PRIVATE KEY—–”的内容拷贝出来,保存为testweb.gdca.com.cn.cn.key,至此私钥提取成功。

4、服务器证书和证书链也可以在testweb.gdca.com.cn.cn.pem提取出来,然后保存成crt文件。

上一篇:

下一篇:

相关新闻

 

领取优惠
免费预约

申请试用SSL证书

提交成功!

咨询客服