Why am I unable to fetch PGP keys from commandline?

I hit this issue several times with different calls of gpg (recommended in tutorials). This time it is:

$ gpg --keyserver pgp.mit.edu --recv-keys 0x4ABA2F66DBD5A95894910E0673D770CDA59047B9
gpg: requesting key A59047B9 from hkp server pgp.mit.edu
gpg: keyserver timed out
gpg: keyserver receive failed: keyserver error

However I am able to download it from and then import.

I wonder why is the PGP client failing - or maybe why the keyserver has disabled possibility of fetching key by the client?

2

1 Answer

HKP, the "HTTP keyserver protocol", is normally spoken on a different port (11371/TCP) than regular HTTP. It could be that you're behind a firewall which blocks all but the most common ports.

Many keyservers do accept HKP on the regular HTTP port, and some of them also work with HKPS (which just shares the HTTPS port). Therefore try one of the following keyservers:

  • hkp://pgp.mit.edu:80
  • hkps://pgp.mit.edu
  • hkps://keyserver.ubuntu.com
  • hkp://p80.pool.sks-keyservers.net:80
  • hkps://hkps.pool.sks-keyservers.net (dried up)
1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like