每次apt update
都显示错误
W: GPG error: https://dl.yarnpkg.com/debian stable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 23E7166788B63E1E
E: The repository 'https://dl.yarnpkg.com/debian stable InRelease' is not signed.
我试过
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
gpg: invalid key resource URL '/etc/apt/trusted.gpg.d/home:stevenpusser.gpg'
gpg: keyblock resource '(null)': General error
gpg: key 7721F63BD38B4796: 2 signatures not checked due to missing keys
使用 y-ppa-manager 我也一样
gpg: invalid key resource URL '/etc/apt/trusted.gpg.d/home:stevenpusser.gpg'
gpg: keyblock resource '(null)': General error
gpg: key 7721F63BD38B4796: 2 signatures not checked due to missing keys
gpg: key 0FAD31CA8719FCE4: 1 signature not checked due to a missing key
gpg: key 3B4FE6ACC0B21F32: 3 signatures not checked due to missing keys
gpg: key D94AA3F0EFE21092: 3 signatures not checked due to missing keys
gpg: key 871920D1991BC93C: 1 signature not checked due to a missing key
我为 Github 身份验证添加了此密钥,因此我害怕将其从列表中删除。我无法找到它
apt-key list
/etc/apt/trusted.gpg
--------------------
pub rsa4096 2016-04-12 [SC]
EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796
uid [ unknown] Google Inc. (Linux Packages Signing Authority) <[email protected]>
sub rsa4096 2019-07-22 [S] [expires: 2022-07-21]
pub rsa4096 2014-09-08 [SC]
67CE 018F D19E 3CD4 8189 BC69 2180 17D1 CC5F DB34
uid [ unknown] Yandex Browser Repository Key <[email protected]>
sub rsa4096 2014-09-08 [E]
pub rsa4096 2018-12-04 [SC] [expires: 2021-01-22]
B44B 85E3 E1A6 386B FC79 D411 9658 E804 4A3A A3D6
uid [ unknown] Vivaldi Package Composer KEY05 <[email protected]>
sub rsa4096 2018-12-04 [E] [expires: 2021-01-22]
提到的文件看起来像是编译后的二进制文件(我猜)
�\ #>p�����N��M�����k��2C�2�����5�Z~W?4����dm��}q�Q���ޠE�m�
!��� 8�GFd]���ǚD�7��X�5�D�LG�E��S��O`{
��n-��1�<�+�*�լ�ak�,���Na����
D�i�5�NÁ��6��C��f�A�z?NTX��`*��`�c��(����\�]8���a��Sw��Dhome:stevenpusser OBS Project <home:[email protected]>�>([��� �
�
�1ʇ����P�:31'���"�Ȭ��|�����������oH��e�М��\*2�m���YF�;z#a2K�g�*��yA�yQ0T@�{"�'��
}dH�[�y�1�X�_5Y��S�218a0��O�� ���j�4;�Àܶ��6ja�J=��}0�f
�\G{E>{U�u��3ުmEÜ!�c9����F�����
������3��T2�%��1}��v�!u����`TcCh\������q� ���Lu����0tc�s$�FW��v
;0�k�e#�K�s���,�%�O~ܺ<���06%�nP2��s�):
我该删除它吗?
如何检查 gpg 资源并解决这个问题?
答案1
我遇到了同样的问题,我只是运行了这个命令:
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
答案2
您通常可以使用以下方法一次更新所有密钥:
sudo apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com
这对我有用
答案3
对于 Ubuntu 20.04,上述命令不起作用,需要使用以下命令来解决此错误:
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | gpg --dearmor | sudo tee /usr/share/keyrings/yarnkey.gpg >/dev/null
答案4
我遇到了同样的错误并使用以下方法修复了它:
sudo apt-key adv --refresh-keys --keyserver keyserver.ubuntu.com