php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #73782 returning nested standard class functions more then 2 layers deep fails
Submitted: 2016-12-19 05:47 UTC Modified: -
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: squarerootofnegativeone at gmail dot com Assigned:
Status: Open Package: SOAP related
PHP Version: 7.1.0 OS: Linux
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: squarerootofnegativeone at gmail dot com
New email:
PHP Version: OS:

 

 [2016-12-19 05:47 UTC] squarerootofnegativeone at gmail dot com
Description:
------------
When a soap server returns nested standard class functions more then 2 layers deep the resulting xml is invalid causing an error on the client side with no error report on the server side.

Test script:
---------------
<?php

//connect to soap server
$options= array(
  'location' 	=>	'https://way.bz/~soap_test',
  'uri'			=>	'https://way.bz/~soap_test',
  'soap_version' => SOAP_1_2
);
$client=new SoapClient(NULL,$options);
		
		
print_r($client->good());		//returns json_decode('{"tc": {"info": "h","st": 7}}');
print_r($client->noGood());		//returns json_decode('{"tc": {"info": {"10": {"l": 0}},"st": {"13": 13}}}');

Expected result:
----------------
Don't expect a fatal error.

Actual result:
--------------
stdClass Object ( [tc] => stdClass Object ( [info] => h [st] => 7 ) ) 
Fatal error: Uncaught SoapFault exception: [Sender] looks like we got no XML document in C:\xampp\htdocs\ipswork\t.php:13 Stack trace: #0 C:\xampp\htdocs\ipswork\t.php(13): SoapClient->__call('noGood', Array) #1 {main} thrown in C:\xampp\htdocs\ipswork\t.php on line 13

Patches

Pull Requests

 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 07 07:01:29 2024 UTC