怎样废弃 PGP 密钥

由于种种原因,比如密钥已经泄露,或者你改了名字或者 email,你很可能需要废弃以前使用的 PGP 密钥,简单地不用它总不太好吧,我们来告诉别人你已经不再用这个密钥了。

以 GnuPG 为例:

首先,我们需要拿到 PGP 密钥的废弃证书:

gpg -o revoke.asc --gen-revoke user-id(替换成你自己的 user-id)

这样我们就把废弃证书写到 revoke.asc 里了。其实废弃密钥应该在产生密钥对的时候就生成,然后放在安全的地方,当然我比较懒……

之后我们导入废弃证书:

gpg --import revoke.asc

这样我们就废弃了这个证书,最后我们把废弃掉的 PGP 公钥发到 keyserver 上。

gpg --send-key key-id

(用 gpg --list-keys 列出 key-id)

好了,这样大家就都知道你的 PGP 密钥已经 revoked 了。

Tags:,

This entry was posted in Information Technology and tagged , . Bookmark the permalink.

2 Responses to 怎样废弃 PGP 密钥

  1. ABitNo says:

    为什么是PGP,不是GPG

  2. Leaf Duo says:

    因为 OpenPGP 还有别的实现

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre lang="" line="" escaped="" highlight="">