Skip to content

fix #6 - enable upload of keys with plain email as uid

mh requested to merge allow-plain-email-as-uid into master

Our current filtering mechanism did not allow for plain emails as uids. Which is what can be done and some people do it.

To safely import keys where there is a plain email in the uid, we can make use of the new mbox import filter, that is available since 2.1.14.

With this we can change our filtering (through import & export) approach:

  1. we detect if we have a single key through simple gpg < keymaterial inspection.
  2. if we have a single key, we record the fingerprint
  3. We import using the mbox filter with a direct match of the email address
  4. We export by matching with the fingerprint

This will give us the exact matching key (through fpr) if there is a direct match on the email, which is all delegated to gpg itself.

Merge request reports