keytool错误:java.lang.Exception:输入不是X.509证书 [英] keytool error: java.lang.Exception: Input not an X.509 certificate

查看:4723
本文介绍了keytool错误:java.lang.Exception:输入不是X.509证书的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图导入Gmail的smtp证书以用于Jira,但是当使用Javas keytool导入时,我得到了此错误。



我使用openssl获取证书, ----开始证书----和---- ----证书----(包含)之间的所有内容。我也尝试使用Windows证书管理器创建一个x.509证书,但仍然出现此错误。我已经验证了文件中没有多余的空格。



我在网上看到很多人遇到这个问题,但没有一个解决方案似乎适用于我。任何帮助将不胜感激。



谢谢 $ c> openssl x509 -outform der -in foo.pem -out foo.der



然后使用DER编码的输出证书。 / p>

I am trying to import Gmails smtp certificate for use with Jira, but I get this error when importing using Javas keytool.

I used openssl to get the certificate, everything between ----Begin Certificate---- and ----End Certificate---- (inclusive). I also attempted to create an x.509 certificate using Windows Certificate Manager, but still get this error. I have verified that there are no extra whitespaces in the file.

I have seen many people with this problem online, but none of the solutions seem to work for me. Any help would be appreciated.

Thanks

解决方案

openssl x509 -outform der -in foo.pem -out foo.der

Then use the DER-encoded output certificate.

这篇关于keytool错误:java.lang.Exception:输入不是X.509证书的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆