diff options
author | Kevin McCarthy <kevin@8t8.us> | 2015-03-30 15:45:55 -0700 |
---|---|---|
committer | Kevin McCarthy <kevin@8t8.us> | 2015-03-30 15:45:55 -0700 |
commit | 15b615710556a2f0960b580d0961421fe5561ce4 (patch) | |
tree | 507101abf559c8f6fcb2ae9afbed11f688d23126 /crypt.c | |
parent | 1d72a322101d00f3962e4d0b5d72e871c5afe755 (diff) |
Add a security bit to the message for oppenc mode.
This allows oppenc to be enabled/disabled on a message level. If
something initially enables encryption, such as crypt_autoencrypt or
crypt_replyencrypt, oppenc is turned off for the message.
Change the postpone/resume code to persist the oppenc bit.
Also change resend message to enable and invoke oppenc if the option is
set.
Diffstat (limited to 'crypt.c')
-rw-r--r-- | crypt.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -773,8 +773,7 @@ void crypt_opportunistic_encrypt(HEADER *msg) if (!WithCrypto) return; - /* crypt_autoencrypt should override crypt_opportunistic_encrypt */ - if (option (OPTCRYPTAUTOENCRYPT)) + if (! (option (OPTCRYPTOPPORTUNISTICENCRYPT) && (msg->security & OPPENCRYPT)) ) return; crypt_get_keys (msg, &pgpkeylist, 1); |