Bug #48289 [Com]: iconv_mime_encode() quoted-printable scheme is broken
| From: | sunfeng891031 at gmail dot com | Date: | Tue, 04 Sep 2012 06:05:45 +0000 |
| Subject: | Bug #48289 [Com]: iconv_mime_encode() quoted-printable scheme is broken | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-173142@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=48289&edit=1
ID: 48289
Comment by: sunfeng891031 at gmail dot com
Reported by: astax dot t at gmail dot com
Summary: iconv_mime_encode() quoted-printable scheme is
broken
Status: Closed
Type: Bug
Package: ICONV related
Operating System: *
PHP Version: 5.*, 6
Assigned To: aharvey
Block user comment: N
Private report: N
New Comment:
thanks!it's useful for me !
i used them in my website:
http://www.dualshine.com
Previous Comments:
------------------------------------------------------------------------
[2012-06-14 07:19:31] jinhuakehao at hotmail dot com
this is great help to design new bug to any backdoors, thanks so much, it's Love
from http://www.favordeal.com
------------------------------------------------------------------------
[2010-05-04 13:57:13] aharvey@php.net
This bug has been fixed in SVN.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
Thank you for the report, and for helping us make PHP better.
------------------------------------------------------------------------
[2010-05-04 13:57:01] aharvey@php.net
Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=298963
Log: Fix for bug #48289 (iconv_mime_encode() quoted-printable scheme is broken).
Thanks to Hiroaki Kawai for the original patch.
------------------------------------------------------------------------
[2010-02-08 03:55:49] astax dot t at gmail dot com
I'd like to test the patch described in #50954. Is it included into any PHP build already?
Sorry, I don't feel like compiling PHP from sources.
Here is one more reproduce code:
$str =
base64_decode("1Ojr6ODrICLH4O/g5O3uLdHo4ejw8ero6SIgzsDOICLR7uHo7eHg7eoiIPDg5CDv8OXk8fLg4ujy/A==");
$par = array(
'scheme' => 'Q',
'input-charset' => 'CP1251',
'output-charset' => 'CP1251',
'line-length' => 74,
);
$res = iconv_mime_encode('Subject', $str, $par);
$res = iconv_mime_decode($res, ICONV_MIME_DECODE_CONTINUE_ON_ERROR, 'CP1251');
echo 'Result: Length='.strlen($res)." ".$res."\n";
$expected = "Subject: ".$str;
echo 'Expected: Length='.strlen($expected)." ".$expected."\n";
It says result length is 74 chars and expected is 67.
------------------------------------------------------------------------
[2010-02-07 17:38:40] jani@php.net
See also bug #50954 (has a patch too)
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=48289
--
Edit this bug report at https://bugs.php.net/bug.php?id=48289&edit=1