Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.14.0

Bug #5003 Client: incoming headers mix with outgoing
Submitted: 2005-08-05 09:12 UTC
From: laihro at gmx dot de Assigned: yunosh
Status: Closed Package: SOAP
PHP Version: 4.3.11 OS: Widows XP SP2
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 23 + 38 = ?

 
 [2005-08-05 09:12 UTC] laihro at gmx dot de
Description: ------------ The http headers are in pear::soap 0.9.1 not properly cleaned between the sending of two messages. If the client receives a message witch headers differ from the next message the client sends, both header sets will be mixed. This behaviour occurs for example when the client recieved an attachment and then tries to send a message without attachments. This problem may produce http errors like "Error 413 Request entity too large". Test script: --------------- [server] <?php if (strpos($HTTP_RAW_POST_DATA, "attachTest") === false) { } else { $response = "------=_Part_13_18150163.1123064466959\nContent-Type: text/xml; charset=UTF-8\nContent-Transfer-Encoding: binary\nContent-Id: <E499622513F9AA87E77E75F8A2F73498>\n\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<soapenv:Envelope xmlns:soapenv=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\n<soapenv:Body>\n<ns1:getZippedCourseResponse soapenv:encodingStyle=\"http://schemas.xmlsoap.org/soap/encoding/\" xmlns:ns1=\"urn:WWRInterface\">\n<ns1:getZippedCourseReturn xsi:type=\"ns2:instance\" xmlns:ns2=\"WWREncoding\">\n<ns1:dataHandler href=\"cid:C8EFC5F183DA5492B74666A49D7603B4\" xmlns:ns3=\"http://xml.apache.org/xml-soap\"/>\n</ns1:getZippedCourseReturn>\n</ns1:getZippedCourseResponse>\n</soapenv:Body>\n</soapenv:Envelope>\n------=_Part_13_18150163.1123064466959\nContent-Type: text/xml\nContent-Transfer-Encoding: binary\nContent-Id: <C8EFC5F183DA5492B74666A49D7603B4>\n\nTEST\n------=_Part_13_18150163.1123064466959--\n"; header("Content-Type: multipart/related; type=\"text/xml\"; start=\"<E499622513F9AA87E77E75F8A2F73498>\"; boundary=\"----=_Part_13_18150163.1123064466959\""); print $response; } ?> [client] <?php require_once 'SOAP/Client.php'; $client = new SOAP_Client("http://localhost/test/server.php"); $param = array(); $client->call("attachTest", $param); $param = array(); $result = $client->call("anything", $param); ?> Suggestion to patch this bug: Change Transport/HTTP.php function &send(&$msg, $options = null) { if (!$this->_validateUrl()) { to function &send(&$msg, $options = null) { $this->headers = array(); if (!$this->_validateUrl()) { Actual result: -------------- Request entity too large! The POST method does not allow the data transmitted, or the data volume exceeds the capacity limit. If you think this is a server error, please contact the webmaster. Error 413

Comments

 [2006-01-06 17:59 UTC] yunosh
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.