gnupg: change default keyserver to non-SKS#63952
Conversation
See https://gist.github.com/rjhansen/67ab921ffb4084c865b3618d6955275f. The SKS network is vulnerable to certificate poisoning, which can destroy GnuPG installations. keys.openpgp.org is a new non-SKS keyserver that is resistant to this type of attack. With such an attack being possible, it is unsafe to use SKS keyservers for almost anything, and so we should protect our users from a now unsafe default. keys.openpgp.org offers some (but not all) functionality of SKS, and is better than nothing. This default is only present in gnupg22. gnupg20 and gnupg1orig are not affected.
|
hi! as one of the folks whose OpenPGP certificate has been affected by this flooding attack, as the author of draft-dkg-openpgp-abuse-resistant-keystore which describes the attack, and as one of the debian developers responsible for co-maintaining both GnuPG and SKS, i'm definitely interested in this sort of change. I'm not convinced that the nice simple change you've done is correct, though. :/ What sort of tests have you run? In particular, i'm concerned that I note that later in the same function, the system CAs might be added as well, which might be why this appears to work for you. i note that |
There was a problem hiding this comment.
Looks good to me, except that this needs to include https://dev.gnupg.org/rG1c9cc97e9d47d73763810dcb4a36b6cdf31a2254 for the reasons @dkg has stated above.
See discussion at NixOS#63952 (comment). Upstream commit: commit 1c9cc97e9d47d73763810dcb4a36b6cdf31a2254 Author: Daniel Kahn Gillmor <dkg@fifthhorseman.net> Date: Sun Jun 30 11:54:35 2019 -0400 dirmngr: Only use SKS pool CA for SKS pool * dirmngr/http.c (http_session_new): when checking whether the keyserver is the HKPS pool, check specifically against the pool name, as ./configure might have been used to select a different default keyserver. It makes no sense to apply Kristian's certificate authority to anything other than the literal host hkps.pool.sks-keyservers.net. Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net> GnuPG-Bug-Id: 4593
|
hi! as one of the folks whose OpenPGP certificate has been affected by this flooding attack, as the author of [draft-dkg-openpgp-abuse-resistant-keystore](https://tools.ietf.org/html/draft-dkg-openpgp-abuse-resistant-keystore) which describes the attack, and as one of the debian developers responsible for co-maintaining both GnuPG and SKS, i'm definitely interested in this sort of change.
Thanks very much for reviewing. It's great to get input from somebody
with so much upstream knowledge.
I'm not convinced that the nice simple change you've done is correct, though. :/ What sort of tests have you run?
I note from the rest of your comment that you saw that it did in fact
appear to work, but just to be clear, I tested a --recv-keys and a
--refresh-keys.
|
|
Got the go ahead from the Hagrid (keys.openpgp.org) people, so I’m going to go ahead and merge this. |
See discussion at NixOS#63952 (comment). Upstream commit: commit 1c9cc97e9d47d73763810dcb4a36b6cdf31a2254 Author: Daniel Kahn Gillmor <dkg@fifthhorseman.net> Date: Sun Jun 30 11:54:35 2019 -0400 dirmngr: Only use SKS pool CA for SKS pool * dirmngr/http.c (http_session_new): when checking whether the keyserver is the HKPS pool, check specifically against the pool name, as ./configure might have been used to select a different default keyserver. It makes no sense to apply Kristian's certificate authority to anything other than the literal host hkps.pool.sks-keyservers.net. Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net> GnuPG-Bug-Id: 4593 (cherry picked from commit ba23c14)
|
Thanks! |
I’ve asked the people behind keys.openpgp.org if they’re ready to become a distro default, and am awaiting a definitive answer from them. Until then this PR should not be merged.
This is a breaking change, but I think it should still be backported to stable because the alternative is leaving people vulnerable.
Motivation for this change
See https://gist.github.com/rjhansen/67ab921ffb4084c865b3618d6955275f.
The SKS network is vulnerable to certificate poisoning, which can destroy GnuPG installations. keys.openpgp.org is a new non-SKS keyserver that is resistant to this type of attack.
With such an attack being possible, it is unsafe to use SKS keyservers for almost anything, and so we should protect our users from a now unsafe default. keys.openpgp.org offers some (but not all) functionality of SKS, and is better than nothing.
This default is only present in
gnupg22.gnupg20andgnupg1origare not affected.Things done
sandboxinnix.confon non-NixOS)nix-shell -p nix-review --run "nix-review wip"./result/bin/)nix path-info -Sbefore and after)