james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Markus Wiederkehr (JIRA)" <server-...@james.apache.org>
Subject [jira] Updated: (MIME4J-90) Consistent parsing of header field names
Date Thu, 04 Dec 2008 19:50:44 GMT

     [ https://issues.apache.org/jira/browse/MIME4J-90?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Markus Wiederkehr updated MIME4J-90:
------------------------------------

    Attachment: mime4j-fieldname.patch

This patch should resolve the issue.

As a consequence it also changes the MimeException thrown by Field#parse back to IllegalArgumentException
(see also MIME4J-73). This is safe now because Field#parse never gets called with an illegal
argument from a ContentHandler. AbstractEntity#parseField already drops invalid header fields.

> Consistent parsing of header field names
> ----------------------------------------
>
>                 Key: MIME4J-90
>                 URL: https://issues.apache.org/jira/browse/MIME4J-90
>             Project: JAMES Mime4j
>          Issue Type: Bug
>    Affects Versions: 0.5
>            Reporter: Markus Wiederkehr
>            Priority: Minor
>             Fix For: 0.6
>
>         Attachments: mime4j-fieldname.patch
>
>
> RFC 822 defines a field as:
>     field       =  field-name ":" [ field-body ] CRLF
>     field-name  =  1*<any CHAR, excluding CTLs, SPACE, and ":">
> This implies that a field name must consist of at least one character and may not contain
spaces or tabs; not even trailing ones.
> Currently o.a.j.mime4j.parser.AbstractEntity#parseField accepts empty field names while
o.a.j.mime4j.field.Field#parse accepts trailing spaces and tabs.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org


Mime
View raw message