Announcement Announcement Module
No announcement yet.
wsdl with HTTP BASIC authentication Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • wsdl with HTTP BASIC authentication

    Hi, I'm using JaxRpcPortProxyFactoryBean to access my webservice. The wsdl URL is secured with HTTP BASIC authentication. Now I have a 401 error when spring try to instantiate the webservice.
    I try to add username and password properties to bean configuration but it didn't work.
    Is there a way to resolve this problem?

    This is my configuration:
    <bean id="sampleService" class="org.springframework.remoting.jaxrpc.JaxRpcPortProxyFactoryBean">
        <property name="serviceInterface" value="org.test.service.SampleService"/>
        <property name="wsdlDocumentUrl" value="http://localhost:8080/sample-ejb-session/SampleServiceBean?wsdl"/>
        <property name="namespaceUri" value=""/>
        <property name="serviceName" value="SampleService"/>
        <property name="portName" value="SampleServicePort"/>
    Thanks, Claudio.
    Last edited by csanchez; Jan 24th, 2007, 02:56 PM.

  • #2
    I guess that getting the wsdl doesn't work as simple http lookup of wsdl will not use username/password you define for the service itself.

    a) store the wsdl as a local file and don't look it up via http
    b) add username and password to the wsdl url


    • #3
      ad b)
      Is it really that easy to pass username/password in HTTP Basic Auth in the URL parameters?

      I thought you had to stored them as a HTTP HEADER parameter and base64 encode it?


      • #4
        Something like
        http://username:[email protected]:8...rviceBean?wsdl
        should do the trick.