invalid byte sequence for UTF8

View: New views
2 Messages — Rating Filter:   Alert me  

invalid byte sequence for UTF8

by Michael Monnerie-5 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Yesterday I saw this error again:

Error:[sql] dbpgsql.c,db_query(+287): query failed [INSERT INTO
dbmail_tofield (physmessage_id, toname, toaddr) VALUES
(2283941,'','"مهند??335?UTF-8?q?ح376tf-8?QD9=85?=اد
<muhannad1979@...>')] : [ERROR:  invalid byte sequence for
encoding "UTF8": 0xdd3f HINT:  This error can also...

Seems dbmail is to blame here, it really must encode the headers
correctly before trying to insert them. Or did I miss something? This is
v2.2.11

mfg zmi
--
// Michael Monnerie, Ing.BSc    -----      http://it-management.at
// Tel: 0660 / 415 65 31                      .network.your.ideas.
// PGP Key:         "curl -s http://zmi.at/zmi.asc | gpg --import"
// Fingerprint: AC19 F9D5 36ED CD8A EF38  500E CE14 91F7 1C12 09B4
// Keyserver: wwwkeys.eu.pgp.net                  Key-ID: 1C1209B4

_______________________________________________
DBmail mailing list
DBmail@...
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail

Re: invalid byte sequence for UTF8

by Paul J Stevens :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Michael Monnerie wrote:

> Yesterday I saw this error again:
>
> Error:[sql] dbpgsql.c,db_query(+287): query failed [INSERT INTO
> dbmail_tofield (physmessage_id, toname, toaddr) VALUES
> (2283941,'','"مهند??335?UTF-8?q?ح376tf-8?QD9=85?=اد
> <muhannad1979@...>')] : [ERROR:  invalid byte sequence for
> encoding "UTF8": 0xdd3f HINT:  This error can also...
>
> Seems dbmail is to blame here, it really must encode the headers
> correctly before trying to insert them. Or did I miss something? This is
> v2.2.11

In this case, the toaddr value doesn't look like an address at all. This
is a garbage-in/garbage-out result where even gmime is unable to
properly decode an address.

Yes, we can add an additional encoding run before inserting broken
addresses, but maybe we should simply drop such addresses from the cache...


--
  ________________________________________________________________
  Paul Stevens                                      paul at nfg.nl
  NET FACILITIES GROUP                     GPG/PGP: 1024D/11F8CD31
  The Netherlands________________________________http://www.nfg.nl
_______________________________________________
DBmail mailing list
DBmail@...
http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail