gpt4 book ai didi

security - x.509 V3 扩展 Basic Constraints 和 Key Usage 创建 CA 证书的区别是什么?

转载 作者:太空宇宙 更新时间:2023-11-03 12:39:20 27 4
gpt4 key购买 nike

这两个 Action 看起来是一样的:

  • 在 X.509 证书中使用 Basic Constraints 扩展来表示它是一个 CA 证书,并且
  • 使用 Key Usage 扩展,例如表示公钥可用于证书签名。

这些扩展有什么区别?
它们的用途相同还是相互补充?

最佳答案

“ key 用法”定义了证书中包含的 key 可以做什么。用法示例有:加密、签名、签名证书、签名 CRL。

“基本约束”标识证书的主体是否是允许颁发子证书的 CA。

对于可用于签署证书的证书,信息在某种意义上是重复的:

  • X509v3 基本约束:CA:TRUE --- 可以签署证书
  • X509v3 Key Usage: Key Cert Sign --- 可以签署证书

但是“基本约束”也会指定有效认证链的最大深度。

虽然是重复的,但是根据RFC 3280 --- X.509,你需要同时指定两者.这是 RFC(第 29 页)中的相关段落:

The keyCertSign bit is asserted when the subject public key isused for verifying a signature on public key certificates. If thekeyCertSign bit is asserted, then the cA bit in the basicconstraints extension (section 4.2.1.10) MUST also be asserted.

关于security - x.509 V3 扩展 Basic Constraints 和 Key Usage 创建 CA 证书的区别是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5795256/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com