On Wed, Oct 13, 2010 at 11:35:15AM +0900, Dan Drake wrote:
On Wed, 13 Oct 2010 at 10:41AM +0900, Dan Drake wrote:
I'm wondering if there's any way to get Mutt to decode the filenames of
attachments. Here's a bit from an attachment I received today:

Whoops...I just looked in the archives for this list, and noticed that just
yesterday there was a message answering my question (the "Strange
Attachment Names" thread). Putting

   set rfc2047_parameters=yes

into my .muttrc does exactly what I want.

I'm wondering whether it's now appropriate to change this to default to 'yes'. I understand the reason it isn't yes by default: RFC 2047 says explicitly not to use RFC 2047 decoding on filename parameters. That is because it would cause technically legitimate filenames to have decoding failures when they shouldn't have been decoded. An attachment with
    Content-Type: IMAGE/JPEG; name="=?wonky,no?Q?failure?="
should be able to be saved to a file named "=?wonky,no?Q?failure?=".

But the fact that users are being advised to set rfc2047_parameters=yes without that warning seems to validate my suspicion: technically legitimate file names that would fail RFC 2047 decoding are *much* more rare than file names that have been RFC 2047 encoded in violation of the spec, but that users just want to have saved with the name that the sender gave it.

Mutt should always send with the proper filename encoding (RFC 2231), of course.

Ed

Attachment: signature.txt
Description: Digital signature

Reply via email to