tags:

views:

218

answers:

0

I read that this should only happen if the SOAP server is not using HTTP protocol, but in my case it is.

My WSDL is below. But instead of calling my soapActions (which are parsed correctly by suds):

  <wsdl:binding name="Authentication_x0020_ServiceSoap" type="tns:Authentication_x0020_ServiceSoap">
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
    <wsdl:operation name="Login">
      <soap:operation soapAction="http://127.0.0.1/Login/" style="document" />
      <wsdl:input>
        <soap:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal" />
      </wsdl:output>
    </wsdl:operation>

it instead calls the services specified at the bottom of the WSDL:

  <wsdl:service name="Authentication_x0020_Service">
    <wsdl:port name="Authentication_x0020_ServiceSoap" binding="tns:Authentication_x0020_ServiceSoap">
      <soap:address location="http://127.0.0.1" />
    </wsdl:port>
    <wsdl:port name="Authentication_x0020_ServiceSoap12" binding="tns:Authentication_x0020_ServiceSoap12">
      <soap12:address location="http://127.0.0.1/" />
    </wsdl:port>
    <wsdl:port name="Authentication_x0020_ServiceHttpGet" binding="tns:Authentication_x0020_ServiceHttpGet">
      <http:address location="http://127.0.0.1" />
    </wsdl:port>
    <wsdl:port name="Authentication_x0020_ServiceHttpPost" binding="tns:Authentication_x0020_ServiceHttpPost">
      <http:address location="http://127.0.0.1" />
    </wsdl:port>
  </wsdl:service>

Is this legitimate SOAP parsing, or is suds doing something wrong? The complete wsdl appears below

Thanks! G

    <?xml version="1.0" encoding="utf-8"?>
<wsdl:definitions xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://%(host_and_port)s/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" targetNamespace="http://%(host_and_port)s/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"&gt;
  <wsdl:types>
    <s:schema elementFormDefault="qualified" targetNamespace="http://%(host_and_port)s/"&gt;
      <s:element name="Login">
        <s:complexType>
          <s:sequence>
            <s:element minOccurs="0" maxOccurs="1" name="ipAddress" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="userAgent" type="s:string" />
            <s:element minOccurs="1" maxOccurs="1" name="accountId" type="s:long" />
            <s:element minOccurs="0" maxOccurs="1" name="userName" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="password" type="s:string" />
          </s:sequence>
        </s:complexType>
      </s:element>
      <s:element name="LoginResponse">
        <s:complexType>
          <s:sequence>
            <s:element minOccurs="0" maxOccurs="1" name="LoginResult" type="tns:LoginResultWrapper" />
          </s:sequence>
        </s:complexType>
      </s:element>
      <s:complexType name="LoginResultWrapper">
        <s:complexContent mixed="false">
          <s:extension base="tns:WebMethodResult">
            <s:sequence>
              <s:element minOccurs="0" maxOccurs="1" name="AuthToken" type="s:string" />
              <s:element minOccurs="0" maxOccurs="1" name="Roles" type="tns:ArrayOfString" />
              <s:element minOccurs="1" maxOccurs="1" name="UserId" type="s:long" />
              <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
              <s:element minOccurs="0" maxOccurs="1" name="LoginName" type="s:string" />
              <s:element minOccurs="0" maxOccurs="1" name="PhoneNumber" type="s:string" />
              <s:element minOccurs="0" maxOccurs="1" name="EmailAddress" type="s:string" />
              <s:element minOccurs="0" maxOccurs="1" name="JobTitle" type="s:string" />
              <s:element minOccurs="0" maxOccurs="1" name="CrmAccounts" type="tns:ArrayOfCrmAccountWrapper" />
              <s:element minOccurs="0" maxOccurs="1" name="CssList" type="tns:ArrayOfClientSiteServiceWrapper" />
            </s:sequence>
          </s:extension>
        </s:complexContent>
      </s:complexType>
      <s:complexType name="WebMethodResult">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="Successful" type="s:boolean" />
          <s:element minOccurs="0" maxOccurs="1" name="StatusCode" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="StatusDescription" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ArrayOfString">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="unbounded" name="string" nillable="true" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ArrayOfCrmAccountWrapper">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="unbounded" name="CrmAccountWrapper" nillable="true" type="tns:CrmAccountWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="CrmAccountWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="AccountId" type="s:long" />
          <s:element minOccurs="1" maxOccurs="1" name="ClientId" type="s:long" />
          <s:element minOccurs="0" maxOccurs="1" name="Services" type="tns:ArrayOfServiceOfferingWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ArrayOfServiceOfferingWrapper">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="unbounded" name="ServiceOfferingWrapper" nillable="true" type="tns:ServiceOfferingWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ServiceOfferingWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="ID" type="s:long" />
          <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="AccountReps" type="tns:ArrayOfAccountRepresentativeWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ArrayOfAccountRepresentativeWrapper">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="unbounded" name="AccountRepresentativeWrapper" nillable="true" type="tns:AccountRepresentativeWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="AccountRepresentativeWrapper">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="1" name="Role" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="ImageUri" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="PhoneNumber" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="EmailAddress" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ArrayOfClientSiteServiceWrapper">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="unbounded" name="ClientSiteServiceWrapper" nillable="true" type="tns:ClientSiteServiceWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ClientSiteServiceWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="CssId" type="s:long" />
          <s:element minOccurs="0" maxOccurs="1" name="Client" type="tns:ClientWrapper" />
          <s:element minOccurs="0" maxOccurs="1" name="Site" type="tns:SiteWrapper" />
          <s:element minOccurs="0" maxOccurs="1" name="Service" type="tns:ServiceWrapper" />
          <s:element minOccurs="0" maxOccurs="1" name="PeerGroups" type="tns:ArrayOfPeerGroupWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ClientWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="ClientId" type="s:int" />
          <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="SiteWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="SiteId" type="s:int" />
          <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ServiceWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="ID" type="s:int" />
          <s:element minOccurs="0" maxOccurs="1" name="Abbreviation" type="s:string" />
          <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="ArrayOfPeerGroupWrapper">
        <s:sequence>
          <s:element minOccurs="0" maxOccurs="unbounded" name="PeerGroupWrapper" nillable="true" type="tns:PeerGroupWrapper" />
        </s:sequence>
      </s:complexType>
      <s:complexType name="PeerGroupWrapper">
        <s:sequence>
          <s:element minOccurs="1" maxOccurs="1" name="ID" type="s:int" />
          <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
        </s:sequence>
      </s:complexType>
      <s:element name="ChangePassword">
        <s:complexType>
          <s:sequence>
            <s:element minOccurs="0" maxOccurs="1" name="authenticationToken" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="ipAddress" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="userAgent" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="oldPassword" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="newPassword" type="s:string" />
          </s:sequence>
        </s:complexType>
      </s:element>
      <s:element name="ChangePasswordResponse">
        <s:complexType>
          <s:sequence>
            <s:element minOccurs="0" maxOccurs="1" name="ChangePasswordResult" type="tns:WebMethodResult" />
          </s:sequence>
        </s:complexType>
      </s:element>
      <s:element name="Logout">
        <s:complexType>
          <s:sequence>
            <s:element minOccurs="0" maxOccurs="1" name="authenticationToken" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="ipAddress" type="s:string" />
            <s:element minOccurs="0" maxOccurs="1" name="userAgent" type="s:string" />
          </s:sequence>
        </s:complexType>
      </s:element>
      <s:element name="LogoutResponse">
        <s:complexType>
          <s:sequence>
            <s:element minOccurs="0" maxOccurs="1" name="LogoutResult" type="tns:WebMethodResult" />
          </s:sequence>
        </s:complexType>
      </s:element>
      <s:element name="LoginResultWrapper" nillable="true" type="tns:LoginResultWrapper" />
      <s:element name="WebMethodResult" nillable="true" type="tns:WebMethodResult" />
    </s:schema>
  </wsdl:types>
  <wsdl:message name="LoginSoapIn">
    <wsdl:part name="parameters" element="tns:Login" />
  </wsdl:message>
  <wsdl:message name="LoginSoapOut">
    <wsdl:part name="parameters" element="tns:LoginResponse" />
  </wsdl:message>
  <wsdl:message name="ChangePasswordSoapIn">
    <wsdl:part name="parameters" element="tns:ChangePassword" />
  </wsdl:message>
  <wsdl:message name="ChangePasswordSoapOut">
    <wsdl:part name="parameters" element="tns:ChangePasswordResponse" />
  </wsdl:message>
  <wsdl:message name="LogoutSoapIn">
    <wsdl:part name="parameters" element="tns:Logout" />
  </wsdl:message>
  <wsdl:message name="LogoutSoapOut">
    <wsdl:part name="parameters" element="tns:LogoutResponse" />
  </wsdl:message>
  <wsdl:message name="LoginHttpGetIn">
    <wsdl:part name="ipAddress" type="s:string" />
    <wsdl:part name="userAgent" type="s:string" />
    <wsdl:part name="accountId" type="s:string" />
    <wsdl:part name="userName" type="s:string" />
    <wsdl:part name="password" type="s:string" />
  </wsdl:message>
  <wsdl:message name="LoginHttpGetOut">
    <wsdl:part name="Body" element="tns:LoginResultWrapper" />
  </wsdl:message>
  <wsdl:message name="ChangePasswordHttpGetIn">
    <wsdl:part name="authenticationToken" type="s:string" />
    <wsdl:part name="ipAddress" type="s:string" />
    <wsdl:part name="userAgent" type="s:string" />
    <wsdl:part name="oldPassword" type="s:string" />
    <wsdl:part name="newPassword" type="s:string" />
  </wsdl:message>
  <wsdl:message name="ChangePasswordHttpGetOut">
    <wsdl:part name="Body" element="tns:WebMethodResult" />
  </wsdl:message>
  <wsdl:message name="LogoutHttpGetIn">
    <wsdl:part name="authenticationToken" type="s:string" />
    <wsdl:part name="ipAddress" type="s:string" />
    <wsdl:part name="userAgent" type="s:string" />
  </wsdl:message>
  <wsdl:message name="LogoutHttpGetOut">
    <wsdl:part name="Body" element="tns:WebMethodResult" />
  </wsdl:message>
  <wsdl:message name="LoginHttpPostIn">
    <wsdl:part name="ipAddress" type="s:string" />
    <wsdl:part name="userAgent" type="s:string" />
    <wsdl:part name="accountId" type="s:string" />
    <wsdl:part name="userName" type="s:string" />
    <wsdl:part name="password" type="s:string" />
  </wsdl:message>
  <wsdl:message name="LoginHttpPostOut">
    <wsdl:part name="Body" element="tns:LoginResultWrapper" />
  </wsdl:message>
  <wsdl:message name="ChangePasswordHttpPostIn">
    <wsdl:part name="authenticationToken" type="s:string" />
    <wsdl:part name="ipAddress" type="s:string" />
    <wsdl:part name="userAgent" type="s:string" />
    <wsdl:part name="oldPassword" type="s:string" />
    <wsdl:part name="newPassword" type="s:string" />
  </wsdl:message>
  <wsdl:message name="ChangePasswordHttpPostOut">
    <wsdl:part name="Body" element="tns:WebMethodResult" />
  </wsdl:message>
  <wsdl:message name="LogoutHttpPostIn">
    <wsdl:part name="authenticationToken" type="s:string" />
    <wsdl:part name="ipAddress" type="s:string" />
    <wsdl:part name="userAgent" type="s:string" />
  </wsdl:message>
  <wsdl:message name="LogoutHttpPostOut">
    <wsdl:part name="Body" element="tns:WebMethodResult" />
  </wsdl:message>
  <wsdl:portType name="Authentication_x0020_ServiceSoap">
    <wsdl:operation name="Login">
      <wsdl:input message="tns:LoginSoapIn" />
      <wsdl:output message="tns:LoginSoapOut" />
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <wsdl:input message="tns:ChangePasswordSoapIn" />
      <wsdl:output message="tns:ChangePasswordSoapOut" />
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <wsdl:input message="tns:LogoutSoapIn" />
      <wsdl:output message="tns:LogoutSoapOut" />
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:portType name="Authentication_x0020_ServiceHttpGet">
    <wsdl:operation name="Login">
      <wsdl:input message="tns:LoginHttpGetIn" />
      <wsdl:output message="tns:LoginHttpGetOut" />
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <wsdl:input message="tns:ChangePasswordHttpGetIn" />
      <wsdl:output message="tns:ChangePasswordHttpGetOut" />
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <wsdl:input message="tns:LogoutHttpGetIn" />
      <wsdl:output message="tns:LogoutHttpGetOut" />
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:portType name="Authentication_x0020_ServiceHttpPost">
    <wsdl:operation name="Login">
      <wsdl:input message="tns:LoginHttpPostIn" />
      <wsdl:output message="tns:LoginHttpPostOut" />
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <wsdl:input message="tns:ChangePasswordHttpPostIn" />
      <wsdl:output message="tns:ChangePasswordHttpPostOut" />
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <wsdl:input message="tns:LogoutHttpPostIn" />
      <wsdl:output message="tns:LogoutHttpPostOut" />
    </wsdl:operation>
  </wsdl:portType>
  <wsdl:binding name="Authentication_x0020_ServiceSoap" type="tns:Authentication_x0020_ServiceSoap">
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
    <wsdl:operation name="Login">
      <soap:operation soapAction="http://%(host_and_port)s/Login/" style="document" />
      <wsdl:input>
        <soap:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <soap:operation soapAction="http://%(host_and_port)s/ChangePassword/" style="document" />
      <wsdl:input>
        <soap:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <soap:operation soapAction="http://%(host_and_port)s/Logout/" style="document" />
      <wsdl:input>
        <soap:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:binding name="Authentication_x0020_ServiceSoap12" type="tns:Authentication_x0020_ServiceSoap">
    <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
    <wsdl:operation name="Login">
      <soap12:operation soapAction="http://%(host_and_port)s/Login/" style="document" />
      <wsdl:input>
        <soap12:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap12:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <soap12:operation soapAction="http://%(host_and_port)s/ChangePassword/" style="document" />
      <wsdl:input>
        <soap12:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap12:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <soap12:operation soapAction="http://%(host_and_port)s/Logout/" style="document" />
      <wsdl:input>
        <soap12:body use="literal" />
      </wsdl:input>
      <wsdl:output>
        <soap12:body use="literal" />
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:binding name="Authentication_x0020_ServiceHttpGet" type="tns:Authentication_x0020_ServiceHttpGet">
    <http:binding verb="GET" />
    <wsdl:operation name="Login">
      <http:operation location="/Login" />
      <wsdl:input>
        <http:urlEncoded />
      </wsdl:input>
      <wsdl:output>
        <mime:mimeXml part="Body" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <http:operation location="/ChangePassword" />
      <wsdl:input>
        <http:urlEncoded />
      </wsdl:input>
      <wsdl:output>
        <mime:mimeXml part="Body" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <http:operation location="/Logout" />
      <wsdl:input>
        <http:urlEncoded />
      </wsdl:input>
      <wsdl:output>
        <mime:mimeXml part="Body" />
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:binding name="Authentication_x0020_ServiceHttpPost" type="tns:Authentication_x0020_ServiceHttpPost">
    <http:binding verb="POST" />
    <wsdl:operation name="Login">
      <http:operation location="/Login" />
      <wsdl:input>
        <mime:content type="application/x-www-form-urlencoded" />
      </wsdl:input>
      <wsdl:output>
        <mime:mimeXml part="Body" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="ChangePassword">
      <http:operation location="/ChangePassword" />
      <wsdl:input>
        <mime:content type="application/x-www-form-urlencoded" />
      </wsdl:input>
      <wsdl:output>
        <mime:mimeXml part="Body" />
      </wsdl:output>
    </wsdl:operation>
    <wsdl:operation name="Logout">
      <http:operation location="/Logout" />
      <wsdl:input>
        <mime:content type="application/x-www-form-urlencoded" />
      </wsdl:input>
      <wsdl:output>
        <mime:mimeXml part="Body" />
      </wsdl:output>
    </wsdl:operation>
  </wsdl:binding>
  <wsdl:service name="Authentication_x0020_Service">
    <wsdl:port name="Authentication_x0020_ServiceSoap" binding="tns:Authentication_x0020_ServiceSoap">
      <soap:address location="http://%(host_and_port)s/%(service_name)s" />
    </wsdl:port>
    <wsdl:port name="Authentication_x0020_ServiceSoap12" binding="tns:Authentication_x0020_ServiceSoap12">
      <soap12:address location="http://%(host_and_port)s/%(service_name)s" />
    </wsdl:port>
    <wsdl:port name="Authentication_x0020_ServiceHttpGet" binding="tns:Authentication_x0020_ServiceHttpGet">
      <http:address location="http://%(host_and_port)s/%(service_name)s" />
    </wsdl:port>
    <wsdl:port name="Authentication_x0020_ServiceHttpPost" binding="tns:Authentication_x0020_ServiceHttpPost">
      <http:address location="http://%(host_and_port)s/%(service_name)s" />
    </wsdl:port>
  </wsdl:service>
</wsdl:definitions>