I use nusoap library to create a webservice with PHP (like this : http://www.sanity-free.org/125/php_webservices_and_csharp_dotnet_soap_clients.html).
The client is in C#.
With http, all works normally.
With https, I have an error in visual studio when trying to add the service :
"There was an error dowloading https://service?wsdl". The request was aborted : could not create SSL/TLS secure channel.
Is this linked to schemas on http ?
<definitions xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://services/soap/SimpleService" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://services/soap/SimpleService">
There is no https in the targetNamespace... I don't know how to solve that in the code.
Thanks for help !
I had the same problem, as it was working fine on http, but wasn't on https. Just to share my whole programming path here, to help others.
I originally followed this tutorial: php webservice with nusoap and c#. Only thing he doesn't say in the tutorial is that you should put all the php code in one php file (but ok, it might be just straightforward really, so no real complaints on that one).
I first tried this on http, and I was happy it worked, but later I had to move to ssl, and since I was testing it on my local server I had a selfsigned certificate, and I got the error: "The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel."
I googled and finally found the solution on this link here: damir dobric blog
Basically you should add the line:
ServicePointManager.ServerCertificateValidationCallback +=
new System.Net.Security.RemoteCertificateValidationCallback(
customXertificateValidation);
and add the implementation of the function customXertificateValidation to return true (this is what I did for testing purposes).