I'm using SoapClient in PHP to connect WS .NET. Here is a part of wsdl :
<wsa10:EndpointReference>
<wsa10:Address>-------------</wsa10:Address>
<Identity xmlns="http://schemas.xmlsoap.org/ws/2006/02/addressingidentity">
<KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
<X509Data>
<X509Certificate>
hfWyLJxqZRtXrHw4slQBxEU8SGgHhQsYsRS...
</X509Certificate>
</X509Data>
</KeyInfo>
</Identity>
</wsa10:EndpointReference>
Here is my code to connect :
$client = new SoapClient($wsdl, array('soap_version' => SOAP_1_2, 'login' => 'login', 'password'=>'password' , 'trace' => 1));
$auth = new stdClass();
$auth->ecodedValue = $hash;
$header = new SoapHeader('http://schemas.xmlsoap.org/ws/2006/02/addressingidentity', 'identity', $auth, false);
$client->__setSoapHeaders($header);
and xml will be generated like that :
<?xml version="1.0" encoding="UTF-8"?>
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope" xmlns:ns1="http://tempuri.org/" xmlns:ns2="http://schemas.xmlsoap.org/ws/2006/02/addressingidentity">
<env:Header>
<ns2:identity>
<encodedValue>MIIEvjC</encodedValue>
</ns2:identity>
</env:Header>
<env:Body>
<ns1:GetBalanceByPhoneNumber>
<ns1:phoneNumber>------------</ns1:phoneNumber>
</ns1:GetBalanceByPhoneNumber>
</env:Body>
</env:Envelope>
What format of xml should I generate to pass certificate of WS? I'm waiting for your help :(.Thanks!