I’ve noticed some confusing behaviours:

First, there is a spurious 2048 bit RSA key being created, which lacks any 
passphrase, when using Thunderbird 52.7.0 with Enigmail 2.0.2.  There is 
already a key for the email account in question, although the email address is 
not set to be the primary uid, and the key has a passphrase, although gpg-agent 
works fine for other MUAs.

There are numerous problems with creating a new key when a valid key already 
exists:  It breaks for users who decrypt their mail on multiple devices.  It’s 
insecure for users who manage their key’s more rigorously, like by keeping 
their root SC private key offline, using short expirations, using a smart card, 
etc.


Second, there is no way to suppress this behaviour from within Thunderbird.  If 
you go to  [account] -> View settings for this account -> OpenGPG Security  and 
then click the Enable OpenPGP security Enigmail toggle box then may select to 
use a specific key, but this setting appears to be ignored and sometimes gets 
erased later.

As an aside, anytime you click this box it asks if you want to disable pEp, but 
clicking cancel still checks the box, so you must uncheck it and click cancel 
again.


At present the only easy solution I’ve found is:

gpg -K | grep rsa2048  # yields the spurious_key_id assuming you never use 2048 
bit keys yourself
gpg --delete-secret-keys spurious_key_id
sudo chown root .gnupg/private-keys-v1.d
sudo chmod 550 .gnupg/private-keys-v1.d

I’ve only done cursory testing of this workaround, but no obvious harmful side 
effects arose.  You must obviously reverse these changes to do private key 
management, preferably without Thunderbird running.  Also contacts might send a 
messages encrypted to the wrong key, so they may need to run:

gpg --delete-keys spurious_key_id

You could easily wind up with numerous spurious_key_id by messing around with 
this.  Assuming you’ve never used a 2048 bit key then your contacts could 
generate commands to delete them all by running:

gpg -k | grep your_email_address -B 2 | grep rsa2048 | cut -c15-33 | sed -e 
's/^/gpg --delete-keys /'


A cleaner workaround would be replacing the gpg binary used by Enigmail/pEp 
with a wrapper script that blocks attempts to create new keys, perhaps by 
blocking the --quick-generate-key option, or else permits Enigmail/pEp to 
generate its own key but adds the —homedir to prevent breaking the user’s 
.gnupg database.

I’m hoping that someone here can tell me how to force Enigmail/pEp in 
Thunderbird to use the correct GPG key, preferably without deactivating pEp.

Best,
Jeff

p.s.  Just fyi, the system is MacOS 10.13.4 with gpg installed both from 
MacPorts (gpg 2.2.6 libgcrypt 1.8.2) and MacGPG2 (gpg 2.2.3 libgcrypt 1.8.1), 
which causes a warning when accessing gpg-agent "gpg: WARNING: server 
'gpg-agent' is older than us (2.2.3 < 2.2.6)”, but retargeting 
/usr/local/bin/gpg symlink to fix this warning seemingly had no effect.  I’ve 
not tested for this behaviour in Enigmail/pEp on Linux due to using other MUAs.


Attachment: signature.asc
Description: Message signed with OpenPGP

_______________________________________________
enigmail-users mailing list
[email protected]
To unsubscribe or make changes to your subscription click here:
https://admin.hostpoint.ch/mailman/listinfo/enigmail-users_enigmail.net

Reply via email to