|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #36854 SOAP Server cannot issue a SoapFault when a SoapClient is created
Submitted: 2006-03-25 01:13 UTC Modified: 2006-03-27 18:40 UTC
From: markslemko at gmail dot com Assigned:
Status: Closed Package: SOAP related
PHP Version: 5.1.2 OS: sever 2003 & Open BSD
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: markslemko at gmail dot com
New email:
PHP Version: OS:


 [2006-03-25 01:13 UTC] markslemko at gmail dot com
I am trying to use a SOAP client within a SOAP server and it caused the SOAP server to fail to respond properly to its clients with a SoapFault when a problem arose. It works fine if there is no error to return to the client.

so a diagram might help...

[SOAP Client A]
[SOAP Server A]
  +[SOAP Client B] ---> [SOAP Server B]
  +[return SoapFault]

...looks like we got no XML document...

The response (SoapFault) to the SOAP Client A looks like it is empty. I'm wondering if the SoapFault mechanism is corrupted by the SoapClient initialization. I've tested the idea of faking a response from the SOAP Server B, i.e. don't create a SOAP Client B, and the returning SoapFault works as expected.

Reproduce code:
// code snippets to get help my issue accross
$server = new SoapServer(null,array('uri'=>$NAMESPACE));

// a class that creates a soap client within the server
class MyClass {
public function Make($something) {
  $client = new SoapClient('');  
  return new SoapFault('Validation','bogus');

// -- another file -- an originating client
try {
$clientA = new soapClient('http://localhost/soap.php');
} catch (SoapFault $e) {
echo $e->faultstring; // error occurs here. wrong error message => expected "bogus"

Expected result:
expected the message "bogus" to be echoed

expect to catch a SoapFault with an error message on the originating client (Client A above).

Actual result:
looks like we got no XML document


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2006-03-26 00:44 UTC]
Please try using this CVS snapshot:
For Windows:

 [2006-03-27 18:32 UTC] markslemko at gmail dot com
It is working on the latest CVS snapshot! 
 [2006-03-27 18:40 UTC]
Works -> closed.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed May 22 19:01:31 2024 UTC