Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.8.8

Bug #10298 Mail_mime, double Quotes and Specialchars in from and to Adress
Submitted: 2007-03-07 12:30 UTC Modified: 2009-12-28 19:12 UTC
From: Ota Assigned: cipri
Status: Closed Package: Mail_Mime (version CVS)
PHP Version: 5.1.4 OS: Linux
Roadmaps: 1.4.0, 1.4.0a3, 1.4.0a2    
Subscription  


 [2007-03-07 12:30 UTC] Ota (Ota Mares)
Description: ------------ Mail_mime Version: CVS: $Id: mime.php,v 1.62 2006/12/06 14:44:39 cipri Exp $ When you have a from or to adress with a name that is encased by double quotes and includes special chars like german umlauts the encoded result does not get validated by Mail_RFC822. As example, following encoded adress fails to get validated: '"German Umlauts öäü" <adresse@adresse.de>' => '"German Umlauts=?ISO-8859-1?Q?=20=F6=E4=FC?=" <adress@adress.de>' Validation failed for: "German Umlauts=?ISO-8859-1?Q?=20=F6=E4=FC"?= <adress@adress.de> The Problem is that the encoding prefix and/or suffix are/is placed outside the double quotes like in the example above (.. FC"?= ...) Currently i dont have a fix at hand.

Comments

 [2007-03-07 12:43 UTC] ota (Ota Mares)
Small typo in the submited bug. The encoded string is '"German Umlauts=?ISO-8859-1?Q?=20=F6=E4=FC"?= not '"German Umlauts=?ISO-8859-1?Q?=20=F6=E4=FC?="
 [2007-03-08 12:21 UTC] cipri (Cipriano Groenendal)
Thank you for taking the time to report a problem with the package. Unfortunately you are not using a current version of the package -- the problem might already be fixed. Please download a new version from http://pear.php.net/packages.php If you are able to reproduce the bug with one of the latest versions, please change the package version on this bug report to the version you tested and change the status back to "Open". Again, thank you for your continued support of PEAR. Please try the new Mail_Mime 1.4.0a1 package as it contains a lot of fixes.
 [2007-03-27 14:43 UTC] cipri (Cipriano Groenendal)
Reopened as Bug #10306
 [2007-04-05 05:43 UTC] cipri (Cipriano Groenendal)
The latest cvs version of mail_mime does not fix the bug, addionaly another bug appears which results from replacing every double quote with =22. The outcome of this is that the email is handled as plain text because the email programm is unable to read the headers. Double quotes are special chars and are reserved for special interpretation, such as delimiting lexical tokens, so you have to maintain them on specific positions. As example the current created boundary header is wrong: boundary=3D=22=3D=5Fcb6a70c3d3376e8701718f180e8a16b3=22?= The correct version would be: boundary="=3D=5Fcb6a70c3d3376e8701718f180e8a16b3" After checking your fix i saw that it only apply's to the non iconv function part. The error also occurs when the iconv functions are available! The perfect solution would be to filter every header value which is delimited by double quotes, extract the value without the double quotes and then apply the encoding function on the filtered string. This is currently not so easy realizable because the headers get exploded on every whitespace.
 [2007-04-05 05:57 UTC] cipri (Cipriano Groenendal)
Thank you for your bug report. This issue has been fixed in the latest released version of the package, which you can download at http://pear.php.net/get/Mail_Mime Fixed in 1.4.0a3
 [2007-05-05 10:06 UTC] cipri (Cipriano Groenendal)
Thank you for your bug report. This issue has been fixed in the latest released version of the package, which you can download at http://pear.php.net/get/Mail_Mime Fixed in 1.4.0
 [2008-07-07 15:23 UTC] ain (Ain Tohvri)
Seems to be broken in 1.5.2 again. Umlauts are not going through. PEAR Error message: 'Validation failed for: =?UTF-8?Q? J=C3=BCrka=20J=C3=A4rminen=20<shalalala@yahoo.com>?='; That is for "Jürka Järminen <shalala@yahoo.com>"
 [2008-11-18 16:22 UTC] safroe (Sascha Fröhlich)
I agree with my predecessor, this problem is not solved for Mail_mime 1.5.2 (PHP 5.2.0-8+etch13) in Debian etch with latest updates. The error is: Validation failed for: =?ISO-8859-1?Q?Sascha=20Fr=F6hlich=20\<sascha.froehlich@freizeitpl?= =?ISO-8859-1?Q?anet.de\>?= Please contact me for further information.
 [2009-06-01 09:51 UTC] janis (Janis Elmeris)
Why is this closed? This is really not fixed yet. A UTF8 subject is accepted, but neither the "from" address, nor "to" address, nor also "reply-to" address: they are all returned as invalid if there are non-Latin characters.
 [2009-12-28 18:11 UTC] giles_v (Giles Copp)
Agreed, this bug is not fixed, can it be reopened or a reason given for it to be closed? Bug #30 has also been closed without a fix.
 [2009-12-28 19:12 UTC] alec (Aleksander Machniak)
This bug has been fixed in SVN. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better. Fixed in r292402
 [2011-08-04 02:05 UTC] raymondappels (Raymond Appels)
I just updated all my scripts after changed to MDB2 and update PEAR but still got this issue. Here my package list: Archive_Tar 1.3.7 Auth_SASL 1.0.4 Calendar 0.5.4 Console_Getopt 1.3.1 DB 1.7.13 Date 1.4.7 MDB2 2.4.1 MDB2_Driver_mysql 1.4.1 MDB2_Driver_mysqli 1.4.1 Mail 1.2.0 Mail_Mime 1.8.1 Mail_Queue 1.2.7 Net_SMTP 1.5.1 Net_Socket 1.0.10 PEAR 1.9.4 Structures_Graph 1.0.4 XML_Parser 1.3.4 XML_Util 1.2.1 Without Umlauts everything is working fine. Anyone see where the problem is?
 [2011-08-05 20:15 UTC] raymondappels (Raymond Appels)
Sorry, no bug! Sometimes the man in the mirror is not me ;-) Thanks anyway
 [2011-11-27 20:18 UTC] gonzek (Jakub Krezel)
How can I fix the problem? Look at this: $From = "Sklep Orange pl samsung-mobile pl <admin@samsung-mobile.pl>"; working fine $From = "Sklep Orange.pl samsung-mobile.pl <admin@samsung-mobile.pl>"; dont working