开发者社区> 问答> 正文

x509_crt_verify_child方法里用到的这四个方法如果返回值不为0,分别表示什么意思? 1 mbedtls_x509_time_is_future(&child->valid_from); 2 x509_profile_check_md_alg(profile, child->sig_md); 3 x509_profile_check_pk_alg(profile, child->sig_pk); 4 x509_profile_check_key(profile, child->sig_pk

常见问题 设备相关

展开
收起
iot小能手 2018-11-30 16:36:49 2803 0
1 条回答
写回答
取消 提交回答
  • 返回值和所代表的意思分别是:

    MBEDTLS_X509_BADCERT_FUTURE /*< The certificate validity starts in the future. /
    MBEDTLS_X509_BADCERT_BAD_MD /*< The certificate is signed with an unacceptable hash. /
    MBEDTLS_X509_BADCERT_BAD_PK/*< The certificate is signed with an unacceptable PK alg (eg RSA vs ECDSA). /
    MBEDTLS_X509_BADCERT_BAD_KEY /*< The certificate is signed with an unacceptable key (eg bad curve, RSA too short). /
    这些都是用于传输层和应用层之间的加密的功能,比如你说的X509是权威机构CA颁发的认证,你那边客户端可以联网上CA确认你连的是不是真正的阿里的服务器。有兴趣可以参考http://freeloda.blog.51cto.com/2033581/1216176

    2019-07-17 23:17:49
    赞同 展开评论 打赏
问答地址:
问答排行榜
最热
最新

相关电子书

更多
OPEN SOURCE IN A DATA-DRIVEN WORLD 立即下载
Borgaonkar-New-Adventures-In-Spying-3G-And-4G-Users-Locate-Track-And-Monitor 立即下载
Using Hadoop to build a Data Quality Service for both real-time and batch data 立即下载