V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
xinyu391

openssl keyusage 有什么用?

  •  
  •   xinyu391 · Aug 8, 2023 · 1682 views
    This topic created in 1002 days ago, the information mentioned may be changed or developed.

    证书的属性中,一般会有 证书密钥用法 如 sunp.eu.org 的浏览证书,会显示是为 ”关键“,”签名“ 而有的网站则显示为 ”关键“,”签名“,”密钥加密“

    在用 openssl 生成证书时,配置

    # This is typical in keyUsage for a client certificate.
    # keyUsage = nonRepudiation, digitalSignature, keyEncipherment
    
    

    我的理解,签名不也是 对 hash 值进行私钥加密,然会公有解密验证吗? 为什么还有这个区分呢?

    2 replies    2023-08-08 13:08:14 +08:00
    keyfunc
        1
    keyfunc  
       Aug 8, 2023
    为了依赖方能根据这些标记来执行不同的处理逻辑。
    billlee
        2
    billlee  
       Aug 8, 2023 via Android
    最小权限原则,虽然一对密钥可以用来做很多事情,但证书只认可其中某几种是有效的。
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3241 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 13:16 · PVG 21:16 · LAX 06:16 · JFK 09:16
    ♥ Do have faith in what you're doing.