Do not add an error if the message is encrypted but not signed

Services like Lacre [1] on Disroot and Inbound Encryption on Posteo [2]
offer to encrypt all incoming messages with the provided OpenPGP
public key. Resulting messages are encrypted, but not end-to-end encrypted
and not signed by the sender, therefore should not have a padlock displayed.
However, such encrypted and unsigned message is also not an indication
of an error on ongoing attack, so we shoud not report this as a problem
to the user.

[1] https://lacre.io/
[2] https://posteo.de/en/help/how-do-i-activate-inbound-encryption-with-my-public-pgp-key
This commit is contained in:
link2xt
2022-12-23 10:19:11 +00:00
parent 7c343411b8
commit 06ead557dc
4 changed files with 65 additions and 5 deletions

View File

@@ -391,11 +391,6 @@ impl MimeMessage {
// part.error = Some("Seems like DKIM failed, this either is an attack or (more likely) a bug in Authentication-Results checking. Please tell us about this at https://support.delta.chat.".to_string());
// }
// }
if encrypted && parser.signatures.is_empty() {
for part in parser.parts.iter_mut() {
part.error = Some("No valid signature".to_string());
}
}
if parser.is_mime_modified {
parser.decoded_data = mail_raw;