Closed athandor closed 9 years ago
There is no way to do this. I would recommend putting pressure on Microsoft to support internet standards that have been around for nearly 20 years (first standardized in 1997).
MimeKit follows the widely accepted internet rules of "be strict in what you send, but liberal in what you accept".
You are right there! Thank you
For what it's worth, I added support to encode using rfc2047 a while back:
There are now 2 ways of controlling the encoding method used for parameter values.
The first way is to set the encoding method on each individual Parameter:
param.EncodingMethod = ParameterEncodingMethod.Rfc2047;
The second way is to set the default parameter encoding method on the FormatOptions used for writing out the message and/or MIME part(s):
var options = FormatOptions.Default.Clone ();
options.ParameterEncodingMethod = ParameterEncodingMethod.Rfc2047;
message.WriteTo (options, stream);
We are using MailKit/MimeKit in our application to send e-mails to users. These e-mails often have attachments with Unicode or long file names. Some e-mail clients, such as Outlook (when using POP or IMAP) or Outlook Express, cannot handle RFC 2231, and the result is that the attachments have names 'Untitled Attachment'.
Is there a way to send mails supporting RFC 2047 (encoded-words) for attachments file names? A possible solution would be to keep RFC 2231 in filename in content-disposition, but use as a fall-back an encoded-word encoded name parameter in content-type. Is something like this supported?
Thanks in advance!