How To wright Long filenames in "Content-Disposition: attachment; filename" in one line with out the file being writen to a new line
Oryx101 opened this issue · 1 comments
Oryx101 commented
Describe the bug
Hi this is a question regarding the long file name in Content-Disposition
I have the following results
--=-bZKVCIXpY0l5CEODeHPLgg==
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: base64
QUFBDQo=
--=-bZKVCIXpY0l5CEODeHPLgg==
Content-Type: application/octet-stream;
name*0="This_IS_abcdefg_CTU_ABCDEFGHIKLMNOP__Bordereaux_(AUG-2012)_COMM_4";
name*1="30 - Test This Services Services_2023-07-21_1042.xlsx"
Content-Disposition: attachment;
filename*0="This_IS_abcdefghijklm_CTU_ABCDEFGHIKLMNOP__Bordereaux_(AUG-2012)_CO";
filename*1="MM_430 - Test This Services_2023-07-21_1042.xlsx"
Content-Transfer-Encoding: base64
How can I keep the Content-Disposition filename on one line...
something like this:
Content-Disposition: attachment;
filename*0="This_IS_abcdefghijklm_CTU_ABCDEFGHIKLMNOP__Bordereaux_(AUG-2012)_COMM_430 - Test This Services_2023-07-21_1042.xlsx"
Content-Transfer-Encoding: base64
Platform (please complete the following information):
- OS: Windows
- .NET Version: 2022 version 17.6
- MimeKit Version: 2.9.0.0
Additional context
I know it seems like a simple question but something I have been struggling with
solutions I have tried
changing the ContentDisposition Encoding
FormatOptions MaximumLineLength
and manipulating the ContentDisposition filename after the fact
this did not work or i implemented the solutions at the wrong place
jstedfast commented
This isn't possible to do with MimeKit, it will always (properly) fold long header lines.