Don't break Content-Type header with LF

This commit is contained in:
Piotr F. Mieszkowski 2022-06-02 19:37:06 +02:00
parent 9820e42457
commit 06abbc0edd
1 changed files with 1 additions and 1 deletions

View File

@ -221,7 +221,7 @@ def encrypt_all_payloads_mime( message, gpg_to_cmdline ):
if 'Content-Type' in message:
message.replace_header('Content-Type', "multipart/encrypted; protocol=\"application/pgp-encrypted\";\nboundary=\"%s\"\n" % boundary)
else:
message['Content-Type'] = "multipart/encrypted; protocol=\"application/pgp-encrypted\";\nboundary=\"%s\"\n" % boundary
message['Content-Type'] = "multipart/encrypted; protocol=\"application/pgp-encrypted\"; boundary=\"%s\"\n" % boundary
return [ pgp_ver_part, encrypt_payload(encrypted_part, gpg_to_cmdline, check_nested) ]