junrest 0 Newbie Poster

Hi, I'm newbie in nusoap library, and I'm getting stuck how to declare soap:header to be use in authentication from the client to the server. My script/wsdl server works fine, but I just want to secure my functions using authentication and also as of now dont have any idea how to set up soap:header on my server. Here's my WSDL server using PHP

<?xml version="1.0" encoding="ISO-8859-1"?>
<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="urn:Calculator" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="urn:Calculator">
<types>
<xsd:schema targetNamespace="urn:Calculator"
>
 <xsd:import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
 <xsd:import namespace="http://schemas.xmlsoap.org/wsdl/" />
 <xsd:complexType name="sample">
  <xsd:sequence>
   <xsd:element name="input1" type="xsd:integer" nillable="false"/>
   <xsd:element name="input2" type="xsd:integer" nillable="true"/>
   <xsd:element name="operation" type="xsd:string" nillable="true"/>

  </xsd:sequence>
 </xsd:complexType>
</xsd:schema>
</types>
<message name="ComputationRequest">
  <part name="Input" type="tns:sample" /></message>
<message name="ComputationResponse">
  <part name="Result" type="tns:sample" /></message>
<portType name="Calculator_ServerPortType">
  <operation name="Computation">
    <input message="tns:ComputationRequest"/>

    <output message="tns:ComputationResponse"/>
  </operation>
</portType>
<binding name="Calculator_ServerBinding" type="tns:Calculator_ServerPortType">
  <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
  <operation name="Computation">
    <soap:operation soapAction="urn:Calculator_Server#Computation" style="rpc"/>
    <input><soap:body use="encoded" namespace="urn:Calculator_Server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></input>
    <output><soap:body use="encoded" namespace="urn:Calculator_Server" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/></output>
  </operation>

</binding>
<service name="Calculator_Server">
  <port name="Calculator_ServerPort" binding="tns:Calculator_ServerBinding">
    <soap:address location="http://ws16.racequeen.local/RQIPRO/branches/jun_new/RQIPRO_NUSOAP_CLIENT_SERVER/rqipro_server/sipport/sipport_server_post.php"/>
  </port>
</service>
</definitions>

-------------------------------------------------------------------------------------------------

Heres the server server I want to create:

<wsdl:binding name="Calculator_ServerBinding" type="ngnpro:Calculator_ServerBindingPortType">
  <wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
  <wsdl:operation name="addAccount">
  <wsdlsoap:operation soapAction=""/>
  <wsdl:input name="AddCustomerAccountRequest">
  <wsdlsoap:header message="ngnpro:Login" part="auth" use="encoded" namespace="urn:AGProjects:NGNPro" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
  <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:AGProjects:NGNPro:Customer" use="encoded"/>
  </wsdl:input>
  <wsdl:output name="AddCustomerAccountResponse">
  <wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:AGProjects:NGNPro:Customer" use="encoded"/>
  </wsdl:output>
  </wsdl:operation>
</wsdl:binding>
<service name="Calculator_Server">
  <port name="Calculator_ServerPort" binding="tns:Calculator_ServerBinding">
    <soap:address location="http://ws16.racequeen.local/RQIPRO/branches/jun_new/RQIPRO_NUSOAP_CLIENT_SERVER/rqipro_server/sipport/sipport_server_post.php"/>
  </port>
</service>