You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spamassassin.apache.org by bu...@bugzilla.spamassassin.org on 2014/08/14 02:30:20 UTC

[Bug 7073] Oddly-formed MIME-Version header prevents base64 decoding

https://issues.apache.org/SpamAssassin/show_bug.cgi?id=7073

--- Comment #1 from Mark Martinec <Ma...@ijs.si> ---
  Date: Wed, 13 Aug 2014 10:39:11 -0400
  MIME-version: 1.0;
  ----_64617665407069666b652e6f7267_Content-type: text/html; charset=UTF-8
  Content-Transfer-Encoding: base64

  LS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0NCkV2ZXJ5b25lIGRlc2VydmVz

The header section is supposed to end by an empty line - but, like several
other mail message parsers, SpamAssassin also considers a header to end
when a header field starting with '---' is encountered. This is not strictly
correct, but on the other hand avoids a case where a separator line is
missing and an entire message body is thus considered part of a header,
and a body would then be considered empty.

In the above case the 'Content-Transfer-Encoding: base64' is no longer
considered part of a header section, so the rest of the body is not
decoded according to base64.

> I suspect the header is invalid according to the RFCs, however the original
> message renders correctly in both alpine and the Android email client.

So, garbage-in, garbage-out. Fixing one case would break the other.

-- 
You are receiving this mail because:
You are the assignee for the bug.