Re: [Evolution] Attachment names with =?ISO-8859-1?Q?=E1=F3=E9=ED=F1?= screwed up



Note that RFC 2183 does not require (ie, it doesn't say SHOULD or MUST) 
that the filename attribute be used as the basis for the name of the
saved file.

Oops, what I meant to say was: 2183 doesn't require that the filename
attribute be used as the saved filename, but recommends that it be used
as the BASIS for the filename and that the filename be changed according
to avoid file name conflicts, enusre legal filename on local filesystem,
etc.

RFC 2184 specifies how to deal with long filename parameters and
filenames containing non-ascii characters, but Evolution currently
neither recognizes nor produces RFC2184-compliant MIME-headers.

Here's how different mailers set the filename attribute:

1. Elm and Evolution:
filename="áó éíñ.txt"
2. Mozilla:
filename="=?iso-8859-1?Q?=E1=F3=20=E9=ED=F1=2Etxt?="
3. Outlook
filename="=?iso-8859-1?B?4fMg6e3xLnR4dA==?="
4. Pine
filename*="X-UNKNOWN''%E1%F3 %E9%ED%F1.txt"

1 is illegal since it contains 8-bit characters, which can't occur in a
quoted-text string.

2 and 3 are legal, but don't have the right semantics: if an attribute
value starts and ends with "'s, it's a quoted-string, and so
"=?iso-8859-1?B?4fMg6e3xLnR4dA==?=" refers to the string

=?iso-8859-1?B?4fMg6e3xLnR4dA==?=

and not the intended

áó éíñ.txt

4 is legal, but not RFC 2184-compliant, since extended-value isn't
supposed to have any quotes around it, or spaces within.

The correct way would be:
filename*=X-UNKNOWN''%E1%F3%20%E9%ED%F1.txt

Evolution should generate the correct version, and accept the incorrect
versions (ie, interpret all versions above as "áó éíñ.txt")

-Richard





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]