Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/linux/22.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Linux GPG键新键,但不包含用户ID_Linux_Networking_Key_Gnupg - Fatal编程技术网

Linux GPG键新键,但不包含用户ID

Linux GPG键新键,但不包含用户ID,linux,networking,key,gnupg,Linux,Networking,Key,Gnupg,我添加了一个新的来源 deb http://httpredir.debian.org/debian buster-backports main contrib 到我的raspberry pi上的源代码列表文件。当我更新我的sudo apt以确认更改时,出现以下错误: sudo apt update Hit:1 http://raspbian.raspberrypi.org/raspbian buster InRelease Get:2 http://httpredir.debian.org/d

我添加了一个新的来源

deb http://httpredir.debian.org/debian buster-backports main contrib
到我的raspberry pi上的源代码列表文件。当我更新我的sudo apt以确认更改时,出现以下错误:

sudo apt update
Hit:1 http://raspbian.raspberrypi.org/raspbian buster InRelease
Get:2 http://httpredir.debian.org/debian buster-backports InRelease [46.7 kB]
Get:3 http://archive.raspberrypi.org/debian buster InRelease [32.6 kB]
Err:2 http://httpredir.debian.org/debian buster-backports InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 04EE7237B7D453EC NO_PUBKEY 648ACFD622F3D138
Get:4 http://archive.raspberrypi.org/debian buster/main armhf Packages [330 kB]
Reading package lists... Done
W: GPG error: http://httpredir.debian.org/debian buster-backports InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 04EE7237B7D453EC NO_PUBKEY 648ACFD622F3D138
E: The repository 'http://httpredir.debian.org/debian buster-backports InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
gpg: key E0B11894F66AEC98: new key but contains no user ID - skipped
gpg: Total number processed: 1
gpg:           w/o user IDs: 1
我得到了以下指示:

gpg --recv-keys 04EE7237B7D453EC
gpg --recv-keys 648ACFD622F3D138
gpg --export 04EE7237B7D453EC | sudo apt-key add -
gpg --export 648ACFD622F3D138 | sudo apt-key add -
但当我执行这个命令时:

gpg --recv-keys 04EE7237B7D453EC
我得到这个错误:

sudo apt update
Hit:1 http://raspbian.raspberrypi.org/raspbian buster InRelease
Get:2 http://httpredir.debian.org/debian buster-backports InRelease [46.7 kB]
Get:3 http://archive.raspberrypi.org/debian buster InRelease [32.6 kB]
Err:2 http://httpredir.debian.org/debian buster-backports InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 04EE7237B7D453EC NO_PUBKEY 648ACFD622F3D138
Get:4 http://archive.raspberrypi.org/debian buster/main armhf Packages [330 kB]
Reading package lists... Done
W: GPG error: http://httpredir.debian.org/debian buster-backports InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 04EE7237B7D453EC NO_PUBKEY 648ACFD622F3D138
E: The repository 'http://httpredir.debian.org/debian buster-backports InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
gpg: key E0B11894F66AEC98: new key but contains no user ID - skipped
gpg: Total number processed: 1
gpg:           w/o user IDs: 1
这种输出是否应该发生?我按照说明进行操作,但仍然出现了以前的错误,
公钥不可用
表示他们的密钥有问题。

我找到了答案:

包管理器需要有PGP密钥来验证来自新存储库的包集。 您首先必须从密钥服务器获取密钥,例如SKS one:

$ gpg --recv-keys --keyserver ipv4.pool.sks-keyservers.net 04EE7237B7D453EC
gpg: key E0B11894F66AEC98: public key "Debian Archive Automatic Signing Key (9/stretch) <ftpmaster@debian.org>" imported
gpg: Total number processed: 1
gpg:               imported: 1
$ gpg --recv-keys --keyserver ipv4.pool.sks-keyservers.net 648ACFD622F3D138
gpg: key DC30D7C23CBBABEE: public key "Debian Archive Automatic Signing Key (10/buster) <ftpmaster@debian.org>" imported
gpg: Total number processed: 1
gpg:               imported: 1
那么您的apt更新应该可以工作了