php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #41650 xmlrpc_encode_request() escapes utf-8 literally
Submitted: 2007-06-11 13:00 UTC Modified: 2021-04-13 13:53 UTC
Votes:12
Avg. Score:4.6 ± 0.8
Reproduced:12 of 12 (100.0%)
Same Version:5 (41.7%)
Same OS:3 (25.0%)
From: allan dot jensen at changenetworks dot dk Assigned: cmb (profile)
Status: Wont fix Package: XMLRPC-EPI related
PHP Version: 5.3.5 OS: *
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: allan dot jensen at changenetworks dot dk
New email:
PHP Version: OS:

 

 [2007-06-11 13:00 UTC] allan dot jensen at changenetworks dot dk
Description:
------------
xmlrpc_encode_request XML-escapes literally without first converting 
to UTF-16 as required.

Once fixed the default option should also be changed from escaping 
non-ascii, to escaping non-encodable

Reproduce code:
---------------
xmlrpc_encode_request('method', '€', array('encoding'=>'utf-8'));

Expected result:
----------------
<?xml version="1.0" encoding="utf-8"?>
<methodCall>
<methodName>method</methodName>
<params>
 <param>
  <value>
   <string>&#8364;</string>
  </value>
 </param>
</params>
</methodCall>


Actual result:
--------------
<?xml version="1.0" encoding="utf-8"?>
<methodCall>
<methodName>method</methodName>
<params>
 <param>
  <value>
   <string>&#226;&#130;&#172;</string>
  </value>
 </param>
</params>
</methodCall>


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-06-11 13:01 UTC] allan dot jensen at changenetworks dot dk
The test script should have &#8364; character encoded as utf-8 in order to 
work.
 [2011-02-21 21:03 UTC] jani@php.net
-Package: Feature/Change Request +Package: XMLRPC-EPI related -Operating System: +Operating System: * -PHP Version: 5.2.3 +PHP Version: 5.3.5
 [2021-04-13 13:53 UTC] cmb@php.net
-Status: Open +Status: Wont fix -Assigned To: +Assigned To: cmb
 [2021-04-13 13:53 UTC] cmb@php.net
The xmlrpc extension is unbundled and moved to PECL as of PHP
7.4.0.  I'm temporarily maintaining the extension, but I will not
do any feature additions.  Actually, everybody is likely better
off to switch to something else.  Thus, I'm closing this ticket.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Wed Jun 23 00:01:23 2021 UTC