Edit report at https://bugs.php.net/bug.php?id=61463&edit=1
ID: 61463 Comment by: markus dot rietzler at rzf dot fin-nrw dot de Reported by: markus dot rietzler at rzf dot fin-nrw dot de Summary: cant import schema when using https soapservice Status: Open Type: Bug Package: SOAP related Operating System: linux PHP Version: 5.3.10 Block user comment: N Private report: N New Comment: tried it with php 5.4.0. same error. not able to load the schema. ok: we have to use http-auth to fetch data, also the schema can be loaded without auth. my question is: it is ok to access the uri with https (ssl secured) $client = new SoapClient('https://connect.example.com/portal/portal?wsdl') and then get an answer with <service name="PortalService"> <port name="PortalPort" binding="tns:PortalPortBinding"> <soap:address location="http://connect.example.com:80/portal/portal"/> </port> </service> </definitions> so the soap:address points to http (non ssl!) could this be the error? Previous Comments: ------------------------------------------------------------------------ [2012-04-19 16:33:40] benoit dot chenu at gmail dot com I didn't test but the authentication problem seems to be solved in 5.4.0 : "Fixed basic HTTP authentication for WSDL sub requests." If it's the case, I hope it will also be done in the next 5.3.11 release. In my case, I've "solved" the problem by commenting this lines in ext/soap/php_schema.c (PHP 5.3.8) : //sdl_set_uri_credentials(ctx, (char*)location TSRMLS_CC); doc = soap_xmlParseFile((char*)location TSRMLS_CC); //sdl_restore_uri_credentials(ctx TSRMLS_CC); I suppose that the proxy and http auth problem are not linked. ------------------------------------------------------------------------ [2012-04-19 15:41:39] benoit dot chenu at gmail dot com Hi, I solve the problem by disabling HTTP authentication. It seems that the soap library doesn't use connexion options when requesting external ressources like the xsd. So it's simple to reproduce : - Create an wsdl which call an xsd - Call the wsdl in https with options (proxy or http authentication) Ben ------------------------------------------------------------------------ [2012-04-19 14:48:46] benoit dot chenu at gmail dot com I have the same problem on PHP 5.3.8. The same code works on PHP 5.2.5 for me. I don't use proxy but I use HTTP authentication, ex : $client = new SoapClient( 'https://connect.example.com/portal/portal?wsdl', array( 'login' => 'axis', 'password' => 'axis' ) ); The wsdl import an xsd like this : <xsd:import namespace="http://xxx/" schemaLocation="https://connect.example.com:443/portal/portal?xsd=1"/> This cause the same error : Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Parsing Schema: can't import schema from 'https://connect.example.com:443/portal/portal?xsd=1' ------------------------------------------------------------------------ [2012-03-29 08:24:05] markus dot rietzler at rzf dot fin-nrw dot de nope, proxy_port makes no difference. i wonder whether it is ok to have a mix of https and http in schema. maybe a misconfiguration of the service provider for this soap service. but: it has worked with php 5.3.3 and with 5.3.10 it don't work anymore ------------------------------------------------------------------------ [2012-03-29 00:54:15] jingshangmingzi at gmail dot com The proxy_port parameter has to be an integer. I think you'll have to use 'proxy_port' => 8080 ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=61463 -- Edit this bug report at https://bugs.php.net/bug.php?id=61463&edit=1