该公钥使用了什么编码?

该公钥使用了什么编码?

下面的密钥使用什么编码机制来编码?

-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: SKS 1.1.0

mQGiBD/dywoRBADkaddBEedMhFHGH3wKORuOIDFufSDERmlm2ktj3ma+Ghfwvnuv
vpAj+QYlANh1K86Mm5k0dGOlhZwIr1zB3cIoNqt7TJ62v8w6mc0BA8UWzWJp0i6d
HPa/qeeFFC53B8U1h3FlPrmQGcVeV+hjOPFU7ANDSDm3tduad7NRxAst7QCg/8o+
+2BaAlTnbMB+Xfo23uEEc6UEAK0vD4EUPLfU5snfow1zUPXQUDalOcUP6RIhbi6y
xKRFAIWI+7QgNPZf/Q2CFIRWsXKmW/lyIDSJgs5ruB+Yj8gmBZlrn5KMmW3EcEoH
AhOP+ONZAIOb2LsaAjHjHOuefhlIr1T3gng+kLoD3Yfy2WTugBizeNybAd2nfZyO
JhfWA/4xTfg+Hbcb9n+8sEqgiuyQJEID38Q3FDmwSzRfBMbOJFrf8t/VHPjB7ZSd
shl9GM86TXYnWjspzAjjQB8fxLgIim2mC0T46aRNdE0l2ozxRmS95nr7YuHVA73v
cI5tRn6qa9yLXew1YeN3YWxRfIW2AZG7bkRcXOIdl7tO9KiVpbQUR29kIDxHb2RA
aGVhdmVuLmNvbT6IWAQQEQIAGAUCP93LCggLAwkIBwIBCgIZAQUbAwAAAAAKCRAS
eKGGJJLZCAp7AJ9WqGhOnysRt/b7p+EuC86lhs3iBgCdEVwLgEwcc63OVbBxxFF6
vyiNuNG5Ag0EP93LChAIAPZCV7cIfwgXcqK61qlC8wXo+VMROU+28W65Szgg2gGn
VqMU6Y9AVfPQB8bLQ6mUrfdMZIZJ+AyDvWXpF9Sh01D49Vlf3HZSTz09jdvOmeFX
klnN/biudE/F/Ha8g8VHMGHOfMlm/xX5u/2RXscBqtNbno2gpXI61Brwv0YAWCvl
9Ij9WE5J280gtJ3kkQc2azNsOA1FHQ98iLMcfFstjvbzySPAQ/ClWxiNjrtVjLhd
ONM0/XwXV0OjHRhs3jMhLLUq/zzhsSlAGBGNfISnCnLWhsQDGcgHKXrKlQzZlp+r
0ApQmwJG0wg9ZqRdQZ+cfL2JSyIZJrqrol7DVekyCzsAAgIH/j7FzAvFjCmq3vXW
nDOymAfJgTNyvYB67y0Xu2HXqGlXe92Gkxcf22w4X63TkZqMy7nXRbGc9WI2sr57
oSTJq3+42WHnVQjd9W10TFIgnH2YkuSC3KckMB5hC1yM9wqaIXNhfxXmq3B4V3Uu
KLyM3nQiSgWb9+kST3FxcGWXRB0Ec/tIJ0cNeFtu5IrYDNkRbcHep/BuwXEARUIp
jlUlG7NPIaY4U03I/GSW7/IrG5/H7EsVWQzxRpcC6DcJjxJv2lIATvraXHwNpllO
lPHFb9aABHmTOX7QLrG4FXTPReH6rjf+w5tqJilTMwYdsZIV13U7+NBwVZHFbUdY
MmqhOTiITAQYEQIADAUCP93LCgUbDAAAAAAKCRASeKGGJJLZCMqJAKCzS0hv0EY/
GYdUKOOf3XiiZpu3qwCg9kFBm/GO+t073SsHkeduHT0F6po==
NhFO
-----END PGP PUBLIC KEY BLOCK-----

答案1

它是使用 Radix64(OpenPGP 的 Base64 变体)编码的公共 PGP 密钥——“装甲”。您通常不需要对其进行解码 - 只需将其导入gpg或 PGP 软件即可。

但是,您帖子中的密钥缺少几个换行符(如果密钥在一行中,则 GPG 无法识别)。它应该如下所示:

-----开始 PGP 公钥块-----
版本:SKS 1.1.0

mQGiBD/dywoRBADkaddBEedMhFHGH3wKORuOIDFufSDERmlm2ktj3ma+Ghfwvnuv
vpAj+QYlANh1K86Mm5k0dGOlhZwIr1zB3cIoNqt7TJ62v8w6mc0BA8UWzWJp0i6d
HPa/qeeFFC53B8U1h3FlPrmQGcVeV+hjOPFU7ANDSDm3tduad7NRxAst7QCg/8o+
+2BaAlTnbMB+Xfo23uEEc6UEAK0vD4EUPLfU5snfow1zUPXQUDalOcUP6RIhbi6y
xKRFAIWI+7QgNPZf/Q2CFIRWsXKmW/lyIDSJgs5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HFbUdY
MmqhOTiITAQYEQIADAUCP93LCgUbDAAAAAAKCRASeKGGJJLZCMqJAKCzS0hv0EY/
GYdUKOOf3XiiZpu3qwCg9kFBm/GO+t073SsHkeduHT0F6po==
亚硝酸铵
-----结束 PGP 公钥块-----

gpg说钥匙属于......

pub 1024D/1278A1862492D908 2003-12-15 上帝 <[电子邮件保护]>
子 2048g/1641295AEB24507A 2003-12-15

以上是该命令的输出:

gpg一些密钥.txt

要查看有关此密钥中的数据块(或 PGP 写入的任何数据)的更多信息,请使用:

gpg -vv 某个密钥.txt

要将其导入到本地密钥环,请使用:

gpg --import 一些key.txt

答案2

正如 Greg 所说,它更适合 superuser.com。

然而,答案是:你看到的块是一个“ASCII 装甲”前列腺特发性硬化症(或者通用石油气公钥可用于使用 PGP/GPG 工具加密数据。使用此密钥加密的数据只能由相应密钥的持有者解密私钥。没有必要(也不用)对其进行“解码”。

相关内容