php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #65018 SoapHeader problems with SoapServer
Submitted: 2013-06-12 10:20 UTC Modified: 2013-07-31 12:35 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: guillaume dot lintot at laposte dot net Assigned: dmitry (profile)
Status: Closed Package: SOAP related
PHP Version: Irrelevant 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 you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: guillaume dot lintot at laposte dot net
New email:
PHP Version: OS:

 

 [2013-06-12 10:20 UTC] guillaume dot lintot at laposte dot net
Description:
------------
SoapHeader::mustUnderstand are ignore in SoapServer context

Test script:
---------------
<?php
	class Tool{
		public function TOKEN($id){
			return new SoapHeader('namespace1', 'TOKEN', $id, true);
		}
		public function Method(){}
	}

	$input = $input =
		'<?xml version="1.0"?>'.PHP_EOL.
		'<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="namespace1"'.
		' xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"'.
		' xmlns:xsd="http://www.w3.org/2001/XMLSchema">'.
		'<SOAP-ENV:Header><ns1:TOKEN soapenv:mustUnderstand="1">abc</ns1:TOKEN></SOAP-ENV:Header>'.
		'<SOAP-ENV:Body><ns1:Method /></SOAP-ENV:Body></SOAP-ENV:Envelope>';

	$soap = new SoapServer(null, array('uri' => '127.0.0.1'));
	$soap->setClass('Tool'); $soap->handle($input);
	$out = ob_get_contents(); ob_end_clean();

	echo $out;
?>

Expected result:
----------------
<ns1:TOKEN soapenv:mustUnderstand="1">abc</ns1:TOKEN>

Actual result:
--------------
<ns1:TOKEN>abc</ns1:TOKEN>

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-06-24 17:16 UTC] felipe@php.net
-Status: Open +Status: Assigned -Assigned To: +Assigned To: dmitry
 [2013-07-31 12:34 UTC] dmitry@php.net
Automatic comment on behalf of dmitry@zend.com
Revision: http://git.php.net/?p=php-src.git;a=commit;h=fd8f45452032720d3239af2106434232c95249e2
Log: Fixed bug #65018 (SoapHeader problems with SoapServer)
 [2013-07-31 12:34 UTC] dmitry@php.net
-Status: Assigned +Status: Closed
 [2013-07-31 12:35 UTC] dmitry@php.net
The fix for this bug has been committed.

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/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.


 [2014-10-07 23:17 UTC] stas@php.net
Automatic comment on behalf of dmitry@zend.com
Revision: http://git.php.net/?p=php-src-security.git;a=commit;h=fd8f45452032720d3239af2106434232c95249e2
Log: Fixed bug #65018 (SoapHeader problems with SoapServer)
 [2014-10-07 23:28 UTC] stas@php.net
Automatic comment on behalf of dmitry@zend.com
Revision: http://git.php.net/?p=php-src-security.git;a=commit;h=fd8f45452032720d3239af2106434232c95249e2
Log: Fixed bug #65018 (SoapHeader problems with SoapServer)
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 21 11:01:29 2024 UTC