#49141 [Opn->Bgs]: iconv_mime_encode broken by design for some headers

From: Date: Mon, 03 Aug 2009 16:36:27 +0000
Subject: #49141 [Opn->Bgs]: iconv_mime_encode broken by design for some headers
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-140607@lists.php.net to get a copy of this message
ID: 49141 Updated by: moriyoshi@php.net Reported By: rch at online dot lt -Status: Open +Status: Bogus Bug Type: Feature/Change Request Operating System: Centos 5.3 PHP Version: 5.2.10 New Comment: Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php This function is not designed to encode such headers in the first place. BTW rfc2822 is outdated. RFC5322 is the update. Previous Comments: ------------------------------------------------------------------------ [2009-08-03 14:02:24] rch at online dot lt Description: ------------ iconv_mime_encode is supposed to compose and return a string that represents a valid MIME header field. However, headers like To, CC and others with email addresses don't fit into simple $field_name => $field_value scheme. Please note that these arguments may contain user submitted data and would contain any characters. The function should accept extra argument(s) for email addresses, and check/encode characters like "'<> with quoted-printable encoding too, and others if needed, and do not encode ascii strings that should not be encoded. Please see http://www.faqs.org/rfcs/rfc2822 for valid email header syntax. Reproduce code: --------------- --- From manual page: function.iconv-mime-encode --- ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=49141&edit=1

« previous php.bugs (#140607) next »