php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #55323 SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself
Submitted: 2011-07-30 08:43 UTC Modified: 2011-08-10 14:11 UTC
From: webm4st0r at gmail dot com Assigned: dmitry
Status: Closed Package: SOAP related
PHP Version: Irrelevant OS: Any
Private report: No CVE-ID:
 [2011-07-30 08:43 UTC] webm4st0r at gmail dot com
Description:
------------
While running a soap client in wsdl mode, if the response of a call contains an 
element which is 
an extension, and it contains itself, an infinite loop occurs in resulting in a 
segmentation fault. The provided patch is against 5.3.6, does not produce the 
expected results (but does not segfault), and causes other tests to fail, but it 
identifies where the problem is (to_zval_object_ex). I've confirmed that this also 
occurs in previous versions.

Test script:
---------------
Test script: http://soapbug.privatepaste.com/700d21fc7f
WSDL: http://soapbug.privatepaste.com/4d7e882d61
XSD: http://soapbug.privatepaste.com/43f7a3e274

Expected result:
----------------
object(stdClass)#%d (2) {
  ["accountId"]=>
  int(1234)
  ["parent"]=>
  *RECURSION*
  }
}


Actual result:
--------------
Segmentation fault

Patches

php_encoding.c (last revision 2011-08-01 23:49 UTC) by webm4st0r at gmail dot com)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2011-08-01 23:51 UTC] webm4st0r at gmail dot com
Updated the attached patch with one that appears to produce the correct results 
and passes all existing tests.
 [2011-08-05 05:44 UTC] dmitry@php.net
-Assigned To: +Assigned To: dmitry
 [2011-08-10 13:44 UTC] dmitry@php.net
Automatic comment from SVN on behalf of dmitry
Revision: http://svn.php.net/viewvc/?view=revision&revision=314737
Log: Fixed bug #55323 (SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself)
 [2011-08-10 14:11 UTC] dmitry@php.net
-Status: Assigned +Status: Closed
 [2011-08-10 14:11 UTC] dmitry@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/.

 For Windows:

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


 [2012-04-18 09:49 UTC] laruence@php.net
Automatic comment on behalf of dmitry
Revision: http://git.php.net/?p=php-src.git;a=commit;h=dc5b3231dc607afb73613da56f912fd5152e0532
Log: Fixed bug #55323 (SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself)
 [2012-07-24 23:40 UTC] rasmus@php.net
Automatic comment on behalf of dmitry
Revision: http://git.php.net/?p=php-src.git;a=commit;h=dc5b3231dc607afb73613da56f912fd5152e0532
Log: Fixed bug #55323 (SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself)
 [2013-11-17 09:37 UTC] laruence@php.net
Automatic comment on behalf of dmitry
Revision: http://git.php.net/?p=php-src.git;a=commit;h=dc5b3231dc607afb73613da56f912fd5152e0532
Log: Fixed bug #55323 (SoapClient segmentation fault when XSD_TYPEKIND_EXTENSION contains itself)
 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Sun Apr 20 10:02:06 2014 UTC