![Wine 签名验证错误 - 索引文件下载失败 - 更换镜像无济于事](https://linux22.com/image/907531/Wine%20%E7%AD%BE%E5%90%8D%E9%AA%8C%E8%AF%81%E9%94%99%E8%AF%AF%20-%20%E7%B4%A2%E5%BC%95%E6%96%87%E4%BB%B6%E4%B8%8B%E8%BD%BD%E5%A4%B1%E8%B4%A5%20-%20%E6%9B%B4%E6%8D%A2%E9%95%9C%E5%83%8F%E6%97%A0%E6%B5%8E%E4%BA%8E%E4%BA%8B.png)
当我sudo apt-get update
收到下面显示的错误时。
W: An error occurred during the signature verification.
The repository is not updated and the previous index files will be used.
GPG error: https://dl.winehq.org/wine-builds/ubuntu bionic InRelease:
The following signatures couldn't be verified
because the public key is not available: NO_PUBKEY 76F1A20FF987672F
W: Failed to fetch https://dl.winehq.org/wine-builds/ubuntu/dists/bionic/InRelease
The following signatures couldn't be verified
because the public key is not available: NO_PUBKEY 76F1A20FF987672F
W: Some index files failed to download. They have been ignored, or old ones used instead.
因此我按照以下建议继续更改镜子这个 Ask Ubuntu 答案。然后我重新启动计算机。但我仍然收到上述相同的错误sudo apt-get update
。
让我们尝试重新安装密钥。
$ wget -nc https://dl.winehq.org/wine-builds/Release.key && sudo apt-key add Release.key
File ‘Release.key’ already there; not retrieving. OK
我可能也一样ping -c3 archive.ubuntu.com
,我的数据包丢失率为 0%。我还需要做什么?
答案1
截至 2018-12-19 08:07,有一个新的winehq.key
密钥文件,如上所述这里。
下载新的存储库密钥并将其添加到受信任密钥列表中:
cd /tmp
wget -nc https://dl.winehq.org/wine-builds/winehq.key
sudo apt-key add winehq.key
sudo apt update
正如 @jason-hunter 在评论中提到的,apt update
会询问您是否接受存储库中的更改,否则apt-get update
会显示错误并失败。
答案2
请注意,添加新的密钥文件后,最好使用apt update
而不是apt-get update
,因为它会提示您接受更改。
全文如下:
wget -nc https://dl.winehq.org/wine-builds/winehq.key && sudo apt-key add winehq.key && sudo apt update
答案3
检查https://dl.winehq.org/wine-builds/,有一个新文件winehq.key
。请尝试使用它,因为它的指纹似乎与错误相匹配:
# curl -sL "https://dl.winehq.org/wine-builds/Release.key" | gpg --dry-run --import --verbose
gpg: pub rsa4096/818A435C5FCBF54A 2015-11-23 Sebastian Lackner (WineHQ packages) <[email protected]>
gpg: Total number processed: 1
# curl -sL "https://dl.winehq.org/wine-builds/winehq.key" | gpg --dry-run --import --verbose
gpg: pub rsa3072/76F1A20FF987672F 2018-12-10 WineHQ packages <[email protected]>
gpg: key 76F1A20FF987672F: 1 signature not checked due to a missing key
gpg: Total number processed: 1
答案4
我最近也遇到了同样的错误:
Err:3 https://dl.winehq.org/wine-builds/ubuntu bionic InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 76F1A20FF987672F
事实证明,需要将公钥添加到我的主机。添加密钥是您在此处看到的密钥的最后 8 位数字F987672F
。因此,将其添加到以下内容以将密钥添加到您的主机:
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv F987672F
希望这可以帮助!