将cer转换为pem时OpenSSL编码错误 [英] OpenSSL encoding errors while converting cer to pem

查看:672
本文介绍了将cer转换为pem时OpenSSL编码错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试通过openssl将.cer文件转换为.pem,命令是:

I`m trying to convert the .cer file to .pem through openssl, the command is:

openssl x509 -inform der -in certnew.cer -out ymcert.pem

这就是我得到的错误:

unable to load certificate
140735105180124:error:0D0680A8:asn1 encoding routines:ASN1_CHECK_TLEN:wrong tag:tasn_dec.c:1319:
140735105180124:error:0D07803A:asn1 encoding routines:ASN1_ITEM_EX_D2I:nested asn1 error:tasn_dec.c:381:Type=X509

我在做什么错了?

推荐答案

我也遇到了这个问题.只需将CER重命名为PEM就足够了:)

I had this problem also. Just rename the CER to PEM was enough :)

这篇关于将cer转换为pem时OpenSSL编码错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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