Bug #10489 Updated: quoted_printable_decode() & imap_qprint() decodes control codes.
| From: | jmoore@php.net | Date: | Sun, 29 Apr 2001 10:40:39 +0000 |
| Subject: | Bug #10489 Updated: quoted_printable_decode() & imap_qprint() decodes control codes. | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-52879@lists.php.net to get a copy of this message | ||
ID: 10489
Updated by: jmoore
Reported By: slaygon@NOSPAMcensor.net
Status: Open
Old-Bug Type: *Mail Related
Bug Type: IMAP related
PHP Version: 4.0.4pl1
Assigned To:
Comments:
reclassify
Previous Comments:
---------------------------------------------------------------------------
[2001-04-25 09:51:13] slaygon@NOSPAMcensor.net
quoted_printable_decode() and imap_qprint() decodes control codes aswell. This, I assume, is not
supposed to happen.
Also, these functions happily translate anything with two characters after the = sign (like =EV in
=EVIL), which they shouldn't.
Example:
$foo="This is =00=01 =E4 "=20" =21 =ev =FE string.";
echo "Quoting string "".$foo.""n";
echo "quoted_printable_decode: "".quoted_printable_decode($foo).""n";
echo "preg_replace:
"".preg_replace("/=([2-9A-Fa-f])([0-9A-Fa-f])/e",
"''.chr(hexdec('\1\2')).''", $foo).""n";
Would result in:
Quoting string "This is =00=01 =E4 =2B "=20" =21 =ev =FE string."
quoted_printable_decode: "This is ä + " " ! ï þ string."
preg_replace: "This is =00=01 ä + " " ! =ev þ string."
Am I wrong in assuming that quoted_printable_decode() and imap_qprint() should act as my
preg_replace line above does?
---------------------------------------------------------------------------
ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.php.net/?id=10489&edit=2