Re: non-ascii email forwarding failures

Subject: Re: non-ascii email forwarding failures

Date: Tue, 26 Feb 2019 10:43:12 -0500

To: David Edmondson, Daniel Kahn Gillmor

Cc: notmuch@notmuchmail.org

From: Antoine Beaupré


On 2019-02-26 10:56:34, David Edmondson wrote:
> On Tuesday, 2019-02-26 at 00:33:33 -05, Antoine Beaupré wrote:
>
>> So I have no idea what's going on with mail forwards, but this is the
>> kind of stuff that happens to me all the time and I can't describe
>> correctly enough to file a bug.
>>
>> The gist of it is that, under some weird circumstances, notmuch-emacs
>> (message-mode.el?) will screw up email forwards in a big time. I just
>> forwarded (or did I just reply? not sure) that private email to the list
>> to trigger that bug...
>>
>> I get that from time to time. I think the key is that it's an email I
>> *sent* not *received*, which are somewhat different in their storage
>> mechanism...
>>
>> The first symptom will be that, when sending, I'd get a prompt like
>> this:
>>
>> Non-printable characters found.  Continue sending? (delete, replace, send, edit, ?): 
>
> After looking at something related but not the same, I ended up with:
>
>  ;; Do forward as MIME (the default), but don't show me the
>  ;; MML.
>  ;;
>  ;; Showing the MML causes decoding and recoding problems, where the
>  ;; headers of an message/rfc822 part end up being very long and
>  ;; opensmtpd decides to wrap them via QP encoding. Unfortunately it
>  ;; QP encodes the MIME separators as well. No idea who is actually in
>  ;; the wrong here, but this fixes it so far.
>  message-forward-as-mime t

I have that same setting here...

>  message-forward-show-mml nil

... but this is set to "best". Setting it to "nil" might solve some of
the problems I'm seeing (specifically with forwarding) but do note the
same problems occur when I reply to an email that has a patch with my
last name in it. For example this message construct will yield the same
error as described earlier because the attached patch has "Beaupré" in
it which will freak out message-mode (or whatever is going on here).

Content-Type: multipart/mixed;
	boundary="_004_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_"
MIME-Version: 1.0
--_004_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_
Content-Type: multipart/alternative;
	boundary="_000_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_"

--_000_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Salut Antoine,

[...]

--_000_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

[...]
--_000_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_--

--_004_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_
Content-Type: application/octet-stream; name="CVE-2018-16864.patch"
Content-Description: CVE-2018-16864.patch
Content-Disposition: attachment; filename="CVE-2018-16864.patch"; size=1796;
	creation-date="Tue, 26 Feb 2019 13:23:19 GMT";
	modification-date="Tue, 26 Feb 2019 13:23:19 GMT"
Content-Transfer-Encoding: base64

RGVzY3JpcHRpb246IGpvdXJuYWxkOiBkbyBub3Qgc3RvcmUgdGhlIGlvdmVjIGVudHJ5IGZvciBw
cm9jZXNzIGNvbW1hbmRsaW5lIG9uIHN0YWNrCiBUaGlzIGZpeGVzIGEgY3Jhc2ggKENWRS0yMDE4
LTE2ODY0KSB3aGVyZSB3ZQogd291bGQgcmVhZCB0aGUgY29tbWFuZGxpbmUsIHdob3NlIGxlbmd0
aCBpcyB1bmRlciBjb250cm9sIG9mIHRoZQogc2VuZGluZyBwcm9ncmFtLCBhbmQgdGhlbiBjcmFz
aCB3aGVuIHRyeWluZyB0byBjcmVhdGUgYSBzdGFjawogYWxsb2NhdGlvbiBmb3IgaXQuCiAuCiBU
aGlzIGlzIGEgYmFja3BvcnQgb2YgaHR0cHM6Ly9naXRodWIuY29tL3N5c3RlbWQvc3lzdGVtZC9j
b21taXQvMDg0ZWViODY1Y2E2Mzg4NzA5OGUwOTQ1ZmI0ZTkzYzg1MmI5MWIwZgpBdXRob3I6IEFu
dG9pbmUgQmVhdXByw6kgPGFuYXJjYXRAZGViaWFuLm9yZz4KQnVnLURlYmlhbjogaHR0cHM6Ly9i
dWdzLmRlYmlhbi5vcmcvOTE4ODQxCk9yaWdpbjogRGViaWFuCkJ1ZzogaHR0cHM6Ly9idWd6aWxs
YS5yZWRoYXQuY29tL3Nob3dfYnVnLmNnaT9pZD0xNjUzODU1CkZvcndhcmRlZDogbm90LW5lZWRl
ZApMYXN0LVVwZGF0ZTogMjAxOS0wMS0yMgoKLS0tIHN5c3RlbWQtMjE1Lm9yaWcvc3JjL2pvdXJu
YWwvam91cm5hbGQtc2VydmVyLmMKKysrIHN5c3RlbWQtMjE1L3NyYy9qb3VybmFsL2pvdXJuYWxk
LXNlcnZlci5jCkBAIC02MDIsNyArNjAyLDEwIEBAIHN0YXRpYyB2b2lkIGRpc3BhdGNoX21lc3Nh
Z2VfcmVhbCgKIAogICAgICAgICAgICAgICAgIHIgPSBnZXRfcHJvY2Vzc19jbWRsaW5lKHVjcmVk
LT5waWQsIDAsIGZhbHNlLCAmdCk7CiAgICAgICAgICAgICAgICAgaWYgKHIgPj0gMCkgewotICAg
ICAgICAgICAgICAgICAgICAgICAgeCA9IHN0cmFwcGVuZGEoIl9DTURMSU5FPSIsIHQpOworICAg
ICAgICAgICAgICAgICAgICAgICAgLyogQXQgbW9zdCBfU0NfQVJHX01BWCAoMk1CIHVzdWFsbHkp
LCB3aGljaCBpcworICAgICAgICAgICAgICAgICAgICAgICAgICogdG9vIG11Y2ggdG8gcHV0IG9u
IHN0YWNrLiBMZXQncyB1c2UgYSBoZWFwCisgICAgICAgICAgICAgICAgICAgICAgICAgKiBhbGxv
Y2F0aW9uIGZvciB0aGlzIG9uZS4gKi8gCisgICAgICAgICAgICAgICAgICAgICAgICB4ID0gc3Ry
YXBwZW5kKCJfQ01ETElORT0iLCB0KTsKICAgICAgICAgICAgICAgICAgICAgICAgIGZyZWUodCk7
CiAgICAgICAgICAgICAgICAgICAgICAgICBJT1ZFQ19TRVRfU1RSSU5HKGlvdmVjW24rK10sIHgp
OwogICAgICAgICAgICAgICAgIH0KQEAgLTcxNiw3ICs3MTksOSBAQCBzdGF0aWMgdm9pZCBkaXNw
YXRjaF9tZXNzYWdlX3JlYWwoCiAKICAgICAgICAgICAgICAgICByID0gZ2V0X3Byb2Nlc3NfY29t
bShvYmplY3RfcGlkLCAmdCk7CiAgICAgICAgICAgICAgICAgaWYgKHIgPj0gMCkgewotICAgICAg
ICAgICAgICAgICAgICAgICAgeCA9IHN0cmFwcGVuZGEoIk9CSkVDVF9DT01NPSIsIHQpOworICAg
ICAgICAgICAgICAgICAgICAgICAgLyogU2VlIGFib3ZlIGZvciBzaXplIGxpbWl0cywgb25seSAt
PmNtZGxpbmUKKyAgICAgICAgICAgICAgICAgICAgICAgICAqIG1heSBiZSBsYXJnZSwgc28gdXNl
IGEgaGVhcCBhbGxvY2F0aW9uIGZvciBpdC4gKi8KKyAgICAgICAgICAgICAgICAgICAgICAgIHgg
PSBzdHJhcHBlbmQoIk9CSkVDVF9DT01NPSIsIHQpOwogICAgICAgICAgICAgICAgICAgICAgICAg
ZnJlZSh0KTsKICAgICAgICAgICAgICAgICAgICAgICAgIElPVkVDX1NFVF9TVFJJTkcoaW92ZWNb
bisrXSwgeCk7CiAgICAgICAgICAgICAgICAgfQo=

--_004_eb33b55506b743279ad0320cb4a1f036XBOX01axiscom_--

So it's not just forwarding, unfortunately.

A.

-- 
In god we trust, others pay cash.
                        - Richard Desjardins, Miami
_______________________________________________
notmuch mailing list
notmuch@notmuchmail.org
https://notmuchmail.org/mailman/listinfo/notmuch

Thread: