close
Comments you submit will be routed for moderation. If you have an account, please log in first.
Modify

Opened 7 months ago

Closed 7 months ago

Last modified 5 months ago

#507 closed bug (fixed)

YAM should use "Content-Disposition: attachment" for all attachments

Reported by: damato Owned by: tboeckel
Priority: normal Milestone: YAM 2.9p1
Component: MIME handling Version: 2.9
Severity: minor Keywords:
Cc: OS Platform: All
Blocked By: Blocking:
Release Notes:

fixed a problem with the "Content-Disposition:" MIME header line which was set to 'inline' for plain text attachments. This cause problems with some mail clients (e.g. Apple Mail) which always displayed these attachments as part of the mail text not allowing to save them as separate attachments.

Description

Summary

YAM does currently automatically decide if a plain text attachment will be signaled to be "inlined" or being specified as being an "attachment" by using the "Content-Disposition:" header parameter of a MIME boundary. While this seems to be perfectly valid according to the RFCs, it would be better to always use "attachment" to specify that even a plain text attachment which the user manually added should be an "attachment" rather than just inlining the text under a main letter part.

Steps to reproduce

  1. generate a plain text file and save it as "test.txt"
  2. attach it to an example mail and store it to a folder
  3. have a look at the raw mail. YAM will use "Content-Disposition: inline" because it identifies it as plain text
  4. send this mail to someone with an "Apple Mail" client or an iOS device and note that it will not be displayed as an actual attachment but the text of that plain text attachment will directly display under the main letter part

Expected results

YAM should send manually added attachment with "Content-Disposition: attachment" as otherwise these mails might not be accessible as actual attachments by other mail clients.

Actual results

With such mails there is no possibility to save/export/strip such plain text parts in iOS mail clients or in Apple Mail.

Attachments (0)

Change History (6)

comment:1 Changed 7 months ago by tboeckel

  • Owner set to tboeckel
  • Status changed from new to assigned

comment:2 Changed 7 months ago by tboeckel

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [7578]) * YAM_WR.c, mui/WriteWindow.c: attachments are now always flagged as such in the generated mail instead of letting YAM choose their content disposition on basis of their type (text or not). This closes #507.

comment:3 Changed 7 months ago by damato

(In [7579]) - make sure that "Content-Disposition: inline" will only be used if there is

really a printable part. Use "attachment" otherwise. This refs #507.

comment:4 Changed 7 months ago by damato

  • Resolution fixed deleted
  • Status changed from closed to reopened

I just found out that the "Content-Disposition:" sub-header seems to be completely missing for attached emails. See here:

----=_BOUNDARY.27eff86845557eb6.92
Content-Type: message/rfc822
Content-Description: Test

Return-Path: test@test.de
[...]

So the only two headers emitted are Content-Type and Content-Description if a user forwards an email "as attachment" using the menu option in YAM.

See here, for example, what Apple Mail emits for the same functionality:

--Apple-Mail=_18472E10-8F4F-4251-BE2E-2140FF5A94DF
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename=Abwesenheitsvertretung.eml
Content-Type: message/rfc822;
	x-mac-hide-extension=yes;
	name="Abwesenheitsvertretung.eml"

[...]

So it seems we should at least add the "Content-Disposition: attachment" header as well as specifying a "filename=" parameter which should correspond to the "subject+.eml" pattern.

comment:5 Changed 7 months ago by tboeckel

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [7580]) * YAM_WR.c: mails being forwarded as attachment now get a proper name. This in turn lets YAM generate some more header lines for the attachment part. This closes #507 again.

comment:6 Changed 5 months ago by damato

  • OS Platform set to All
  • Release Notes modified (diff)

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.

This list contains all users that will be notified about changes made to this ticket.

These roles will be notified: Reporter, Owner, Subscriber

  • Jens Maus(Reporter, Participant)
  • Thore Böckelmann(Owner, Participant)