wsdl error: no proper separation of headers and document

前端 未结 2 1140
粉色の甜心
粉色の甜心 2021-01-21 04:05

I\'m using NUSOAP to use a soap interface to microsoftdynamics. I\'m getting this error \"wsdl error: Getting https://testserver2013.api.crm4.dynamics.com/XRMServices/2011/Organ

相关标签:
2条回答
  • 2021-01-21 04:53

    I just saw this error and it appears to be a bug in the nusoap code. In our case this was caused by a 401 error response to the SOAP call but 301 and 302 responses would appear to trigger the same issue.

    The bug appears to be in the following line of code:

    if ($pos = strpos($data,"\r\n\r\n"))

    When headers were stripped $pos is set to 0 and this evaluates to FALSE whereas it appears the developer intended it to evaluate to TRUE along with the case where the headers are intact.

    See: https://github.com/codecasts/nusoap-php7/blob/master/lib/class.soap_transport_http.php

    0 讨论(0)
  • 2021-01-21 04:57

    Check your line endings. The problem can be caused by a mixture of LF and CR+LF in your PHP/source files

    0 讨论(0)
提交回复
热议问题