weixin_39203461
Dr·Chen
采纳率0%
2021-03-01 09:36

Openssl 3.0.0 CMP SM算法 流程

100
已结题

从github拉取了openssl 3.0.0版本,根据说明文档应该是实现了SM国密算法和CMP流程,但使用国密算法进入CMP命令时,总是报错,一般是摘要算法不对或者与密钥不匹配

有人熟悉这块内容,可以留下联系方式交流一下吗?包括国密CMP流程以及cmp服务器相关的问题

 

git clone --branch openssl-3.0.0-alpha4 https://github.com/openssl/openssl.git

cd openssl

./config -d shared

make -j64 && sudo make install

==============================

cd apps
export OPENSLL_CONF=openssl.cnf
wget 'http://pki.certificate.fi:8080/install-ca-cert.html/ca-certificate.crt\?ca-id=632&download-certificate=1' -O insta.ca.crt
openssl ecparam -name SM2 -genkey -out insta.priv.pem
openssl cmp -section insta

# 此处出错
OPENSSL_FUNC:apps/cmp.c:2895:CMP info: using OpenSSL configuration file '/openssl_3.0.0_alpha4/openssl/apps/openssl.cnf'
OPENSSL_FUNC:apps/cmp.c:2112:CMP info: will contact http://pki.certificate.fi:8700/pkix/
pkey_sm2_digest_custom:crypto/sm2/sm2_pmeth.c:282:CMP error: <NULL>
ASN1_item_sign_ctx:crypto/asn1/a_sign.c:262:CMP error: EVP lib
ossl_cmp_certReq_new:crypto/cmp/cmp_msg.c:373:CMP error: error creating ir

# 详情见/openssl/doc/man1/openssl-cmp.pod.in
  • 点赞
  • 收藏
  • 复制链接分享

1条回答