<<< Date Index >>>     <<< Thread Index >>>

mutt/2791: problems with filename MIME parameter and newlines



>Number:         2791
>Notify-List:    
>Category:       mutt
>Synopsis:       problems with filename MIME parameter and newlines
>Confidential:   no
>Severity:       normal
>Priority:       medium
>Responsible:    mutt-dev
>State:          open
>Keywords:       
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Feb 21 04:58:01 +0100 2007
>Originator:     Phil Pennock
>Release:        1.5.13
>Organization:
>Environment:
n/a
>Description:
Create a file with embedded newlines.  Attach it in mutt.  Mail it.  View the 
results in mutt and see that part of the filename ends up shown as attachment 
content.

Whilst RFC2183 has cautions for receiving MUAs, it says little about 
restrictions on sending MUAs.  It seems reasonable though to expect that the 
MUA be able to parse its own output.  :-)
>How-To-Repeat:
Using zsh:
% echo foo > $'foo\n.\nbar'
% mutt -a foo?* -s test recipient
% mutt
view message

In a slightly different test, same file, I saw:
-------
[-- Attachment #3: foo --]                                                      
                                                                                
                                                                            
[-- Type: text/plain, Encoding: 7bit, Size: 0.1K --]                            
                                                                                
                                                                            
                                                                                
                                                                                
                                                                            
bar"                                                                            
                                                                                
                                                                            
                                                                                
                                                                                
                                                                            
foo
------

Viewing headers revealed:
------
[-- Attachment #3: foo --]                                                      
                                                                                
                                                                            
[-- Type: text/plain, Encoding: 7bit, Size: 0.1K --]                            
                                                                                
                                                                            
Content-Type: text/plain; charset=us-ascii                                      
                                                                                
                                                                            
Content-Disposition: attachment; filename="foo                                  
                                                                                
                                                                            
.                                                                               
                                                                                
                                                                            
bar"                                                                            
                                                                                
                                                                            
                                                                                
                                                                                
                                                                            
foo                                                                             
                                                                                
                                                                 
                                                                                
                                                                                
                                                                  ------
>Fix:
Map newline-matching characters to space?  Or question-mark.
>Add-To-Audit-Trail:

>Unformatted: