Launchpad could not import my OpenPGP key

Asked by Wim Lewis

I'm unable to import my key to Launchpad. I enter its fingerprint, click "Import Key", and get the error message ("Launchpad could not import your OpenPGP key. Did you enter your complete fingerprint correctly? [etc]").

My key is on the ubuntu keyserver:

I've tried the fingerprint with no spaces (0C0D10D5FC73D1352646429EDC6E0A88) and various spaces, as well as the key ID, with no luck.

Several other people have had this problem due to the ubuntu->launchpad synchronization being slow, so I waited a couple of days, but Launchpad still won't import it.

Related items:
  Faq 79:
  Similar unresolved question:
  Similar answered question:
  Bug describing this problem, but marked 'invalid':

Question information

English Edit question
Launchpad itself Edit question
Canonical Launchpad Engineering Edit question
Last query:
Last reply:
2011-09-28 thedac: Assigning back to Canonical Launchpad Engineering. LOSAs need more guidance on this issue. Where does the "internal" keyserver live. What mechanism syncs? etc.
Revision history for this message
Max Bowsher (maxb) said :

LOSAs, please could you look into whether there is a problem with the sync from to the internal keyserver?

Also note that this key is a version 3 PGP key (i.e. very old, PGP 2.6.x compatible), and so its key-id is *not* the suffix of the fingerprint as for v4 keys.

Revision history for this message
Brad Crittenden (bac) said :


As mentioned towards the end of the report for , the problem (in that case) was there are multiple keyservers at for load balancing and they were not synchronizing with one another. It is possible that this is the case now.

I will ask the admins to take a look at the keyservers.

Revision history for this message
Wim Lewis (wiml) said :

Ah, my reading of 514704 was that there was a single (hidden) Launchpad keyserver which would occasionally stop synchronizing with Ubuntu's. (nslookup only returns one ip address for for me anyway,, from all 3 Canonical nameservers.) I dug around a little in the Launchpad sources and from and it looks like the internal keyserver is specified in the [gpghandler] section of the site's config. Regardless, is there some reason Launchpad uses such an unreliable keyserver? Why can't it get keys directly from or some other maintained keyserver?

Revision history for this message
Brad Crittenden (bac) said :

First, let me say the admins have bounced the keyservers at It would be helpful if you could report if you are currently still seeing the problem.

Wim, you are correct in what you report from looking at the code that there is an internal keyserver that we maintain in our data center to eliminate the need to hit the public server all of the time.

In the code used for importing GPG keys that internal server is not in play. If you look at the code for browser/ you'll see:

   def keyserver_url(self):
        assert self.fingerprint
        return getUtility(
            IGPGHandler).getURLForKeyInServer(self.fingerprint, public=True)

If you trace that back to you'll see the parameter public=True causes the request to go directly to the public key server not the internal one.

In the past when we've seen import problems (such as described in bug 514704) it was shown to be the public keyservers not synchronizing.

Also, the fact you only see one IP address for the keyserver is not an indication that there is only one true instance. The Wikipedia article on load balancing is quite good.

Revision history for this message
Wim Lewis (wiml) said :

My key is still on the Ubuntu keyserver as far as I can tell (it's visible at ) and still fails to import. Hopefully six months is enough time for the keyservers to synchronize. I'm getting the same error message as before (no specific reason for the failure).

Revision history for this message
Brad Crittenden (bac) said :

Hi Wim,

Thanks for reporting that you are still having problems. I'm sorry that the actions we took a while back didn't solve your issue.

Further investigation shows that the key you are trying to import is a v3 key, which we do not support. Here is the query Launchpad uses to retrieve your key:

If you open that URL you'll see the error response generated by the key server.

The issue was raised a long time ago (but I was unaware of it) as bug 4746.

In that discussion you'll see that we have made the decision not to support v3 keys as they are not as secure.

I am going to convert this question into a bug, though, as the error message you received was misleading.

Revision history for this message
P M (pmehta-g) said :

i am facing this same exact situation where my key is v4 and lookup works just fine,

it is possible that sync is broken again or something else in launchpad code is misbehaving

Can you help with this problem?

Provide an answer of your own, or ask Wim Lewis for more information if necessary.

To post a message you must log in.