mutt stable branch with some hacks

Canonicalize line endings for GPGME S/MIME encryption. (closes #3904)

This matches the behavior for S/MIME classic mode: OpenSSL converts
the line endings to cr/lf before encrypting. Although Mutt always
canonicalizes the line endings before verifying the signature, some
clients do not do this for encrypted messages.

Thanks to cooler for the patch!

+5 -1
+5 -1
crypt-gpgme.c
··· 1091 1091 if (!rset) 1092 1092 return NULL; 1093 1093 1094 - plaintext = body_to_data_object (a, 0); 1094 + /* OpenSSL converts line endings to crlf when encrypting. Some 1095 + * clients depend on this for signed+encrypted messages: they do not 1096 + * convert line endings between decrypting and checking the 1097 + * signature. See #3904. */ 1098 + plaintext = body_to_data_object (a, 1); 1095 1099 if (!plaintext) 1096 1100 { 1097 1101 free_recipient_set (&rset);