Re: [gmime-devel] problem with BOM in header



Hi,

On 5/28/2014 9:19 AM, Andreas Amann wrote:
Hi,

I have some spam mails, which have a utf-16 byte order mark
(BOM) U+FEFF as the first character in one of their "Received:"
lines, before the "From", etc. header lines. When I do

Not much of a BOM if it appears in the *middle* of a file :-)


g_mime_object_get_header (GMIME_OBJECT(message),"From")

I simply get the string "(null)", but not the actual "From" field.  I
suspect that gmime chokes on parsing the BOM, and considers the
remainder of the message to be part of the body.  Is this the expected
behavior or is this a bug in gmime?

I doubt GMime chokes on it - it handles arbitrary 8-bit data in the header values.


Maybe gmime could simply ignore BOMs independent of whether they appear
in the header or body of a message?

AFAICT, it already does.

Can you file a bug at http://bugzilla.gnome.org and attach a sample message file?

Jeff


Attachment: smime.p7s
Description: S/MIME Cryptographic Signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]