OpenPGP签名是否包含签名者的用户ID?

编程入门 行业动态 更新时间:2024-10-10 21:25:56
本文介绍了OpenPGP签名是否包含签名者的用户ID?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我有一个签名的公共密钥.我想查看此OpenPGP公钥中的所有签名.

I have a signed public key. I wanted to view all the signatures in this OpenPGP public key.

我有签名列表,当我尝试获取签名者的用户ID时,什么也没有返回.

I've got the signature list, and when I tried to get the user IDs of the signers, nothing is returned.

所以我怀疑OpenPGP签名是否包含签名者的用户ID.

So my doubt is whether an OpenPGP signature contains the signer's user IDs or not.

我使用Thunderbird查看签名,但是它也显示未找到用于签名的用户ID,并且当我导入与我签名的私钥相对应的公钥时,它会显示签名者的用户ID.

I used Thunderbird to view signatures, but it also show user ID not found for signature and when I imported the public key corresponing to the private key from that I signed, It showes the user ID of the signer.

我的结论是OpenPGP签名不包含签名者的用户ID.它们仅包含密钥ID.如果您还具有签名者的公钥,则它将尝试从该公钥中获取用户ID并显示给您.

My conclusion is OpenPGP signatures don't contain the signer's user IDs. They only contain the key ID. If you also have public key of signer, then it tries to get the user ID from that public key and show you.

注意:我正在使用充气城堡API.

Note: I am using the bouncy castle API.

推荐答案

在签名另一个密钥(分别为该密钥的UID)时,密钥中包含的所有内容都是密钥ID.

When signing another key (respective a UID of this key), all that gets included from your key is the key ID.

Thunderbird尝试将密钥ID解析为密钥的默认UID,但这仅在公钥位于Thunderbird的密钥环中时有效.

Thunderbird tries to resolve that key ID to the key's default UID, but this only works if the public key is in Thunderbird's keyring.

如果要在自己的软件中解析UID,则必须提取密钥的ID并寻找匹配的公共密钥.

If you want to resolve the UID in your own software, you must pull the key's ID and look for a matching public key.

所以我的结论是Pgp签名不包含签名者的用户ID.它仅包含keyid.如果您还具有签名者的公钥,则它会尝试从该公钥中获取用户ID并显示给您.

so My conclusion is Pgp Signature doesn't contain signer's user id. It contains only keyid. If you also have public key of signer then it try to get userid from that public key and show you.

是的,这是唯一的方法.

Yep, that's the only way to do.

更多推荐

OpenPGP签名是否包含签名者的用户ID?

本文发布于:2023-11-24 17:02:18,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1626081.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:用户   OpenPGP   ID

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!