Closed Bug 128735 Opened 23 years ago Closed 20 years ago

Mozilla Mail creates malformed MIME messages

Categories

(MailNews Core :: MIME, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 65794

People

(Reporter: abr, Assigned: bugzilla)

Details

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; ru-RU; rv:0.9.8) Gecko/20020206
BuildID:    2002020609

Mozilla Mail creates malformed MIME messages.  They are no
problem to known HTML mailers, but nevertheless nonstandard.


Reproducible: Always
Steps to Reproduce:
1. Let's create sample HTML letter with one attached image and one more inlined
in HTML part;
2. Let Mozilla know that text/plain part is also needed;
3. View MIME structure of result message.

Actual Results:
Here's the resulting message structure:

multipart/mixed = {
    multipart/alternative = {
        text/plain,
        multipart/related = {
            multipart/related = {
                text/html
            },
            image/png,
        },
    },
    image/png (Content-Disposition: inline)
};

Expected Results: (valid structure)

multipart/mixed = {
    multipart/alternative = {
        text/plain,
        multipart/related = {
            text/html,
            image/png,
        },
    },
    image/png (Content-Disposition: attachment)
}

Problem 1: how it came to two multipart/related?  According to
RFC2387 "The MIME Multipart/Related Content-type. E. Levinson.
August 1998", multipart/related should containt _related_ parts,
and Mozilla left only text/html in inner block leaving image/png
(inline.png, related) outside, thus introducing unnecessary
complexity in the structure.  Seems that inner m/r is redundant.

Problem 2: second image/png (attach.png) got
"Content-Disposition: inline" which really should be "attachment"
as per RFC2183 (2.1, 2.2) where it is clearly stated.
Reporter: This was filed sometime ago.
Could you please test using RC3 or the latest nightly, to see if the bug still
exists.

Thanks.
Reporter: could you please test this bug using the latest nightly build, or
using mozilla 1.0 to see whether it still exists.

Your reply is requested, otherwise this bug will be marked WorksForMe.

Thanks.
I'll answer as soon as possible (in several hours), when i upgrade to Mozilla
1.0-release
I reproduced this bug on Mozilla 1.0 (Build ID: 2002060614).
Message's structure is still invalid, as described above (unnecessary
complexity in the structure) & attached image still has "Content-Disposition:
inline" header instead of "Content-Disposition: attachment".
dupe? bug 160029 comment 19

reporter (Andrey Brindeew), can you verify if this bug has been fixed?
Yes, problem number 1 was resolved, I got valid structure, BUT problem 2 still
exists.
The _attached_ image (jpg) still has "Content-Disposition: inline" header
instead of "Content-Disposition: attachment".
The remaining issue is bug 65794 (see also bug 66915). Workaround:
    user_pref("mail.content_disposition_type", 1);
into user.js or prefs.js.
http://lxr.mozilla.org/mozilla/source/mailnews/compose/src/nsMsgCompUtils.cpp#1005

*** This bug has been marked as a duplicate of 65794 ***
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.