Bug 190563 - Broken header parsing
Broken header parsing
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: evolution (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Matthew Barnes
Depends On:
Blocks: 176344
  Show dependency treegraph
Reported: 2006-05-03 12:21 EDT by Bastien Nocera
Modified: 2008-04-10 13:33 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2006-09-01 05:58:43 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
multipart-mime-email-message.txt (148.96 KB, text/plain)
2006-05-03 12:21 EDT, Bastien Nocera
no flags Details

  None (edit)
Description Bastien Nocera 2006-05-03 12:21:32 EDT

Using the attached message, headers are not parsed properly.

In header_decode_param_list() in camel/camel-mime-utils.c (HEAD
evolution-data-server, or RHEL4 evolution) tries to parse:

Content-Type: multipart/related; type=text/html;

as being of type:
text/html; boundary="_----------=_1144416812592800"

instead of stopping at the ';', so the boundary never gets set.

The result is that the message looks like a text e-mail and no HTML.
Comment 1 Bastien Nocera 2006-05-03 12:21:33 EDT
Created attachment 128541 [details]
Comment 3 RHEL Product and Program Management 2006-08-18 12:02:23 EDT
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
Comment 5 Matthew Barnes 2006-08-31 23:48:36 EDT
devel_ack -- I'll have a look at this.
Comment 6 ritz 2006-09-01 05:58:11 EDT
Evolution (bugzilla.gnome.org) 	
<bugzilla-daemon@bugzilla.gnome.org> to me
	 More options	  Aug 20
Do not reply to this via email (we are currently unable to handle email
responses and they get discarded).  You can add comments to this bug at
 Evolution | Mailer | Ver: 2.7.x

Andre Klapper changed:

          What    |Removed                     |Added
                CC|                            |---
            Status|UNCONFIRMED                 |RESOLVED
        Resolution|                            |NOTABUG

------- Comment #4 from Andre Klapper  2006-08-20 12:07 UTC -------
The content type header has to have *one* value.
it is either text/html for a text only message, like
       Content-Type: text/html
or multi-part/related with a boundary definition for a message containing
attachments, like
       Content-Type: multipart/related; boundary="----=_part_2_2729.1112"

       Content-Type: multipart/related; type=text/html;
is just plain wrong, the sender may file a bug against his broken mail
application ("MIME::Lite 2.117"), but this is not evolution's fault.
Comment 9 norman joseph 2008-04-10 13:33:52 EDT
The vendor from the original call directed me to RFC 2387, "The MIME
Multipart/Related Content-type", where it describes the syntax of the
Content-Type header as:

3.4.  Syntax

     related-param   := [ ";" "start" "=" cid ]
                        [ ";" "start-info"  "="
                           ( cid-list / value ) ]
                        [ ";" "type"  "=" type "/" subtype ]
                        ; order independent

     cid-list        := cid cid-list

     cid             := msg-id     ; c.f. [822]

     value           := token / quoted-string    ; c.f. [MIME]
                           ; value cannot begin with "<"

   Note that the parameter values will usually require quoting.  Msg-id
   contains the special characters "<", ">", "@", and perhaps other
   special characters.  If msg-id contains quoted-strings, those quote
   marks must be escaped.  Similarly, the type parameter contains the
   special character "/".

and where they give further examples showing the "type=..." option:

   The example below, uses a single data block.

     Content-Type: Multipart/Related; boundary=example-1
             start-info="-o ps"

So I believe Andre is wrong stating "Content-Type: multipart/related;
is just plain wrong".  If Thunderbird can handle this header correctly (not to
mention Lotus Notes and MS Outlook" why can't Evolution?

Note You need to log in before you can comment on or make changes to this bug.