Announcement Announcement Module
Collapse
No announcement yet.
wsdl with HTTP BASIC authentication Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • 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:
    Code:
    <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="http://service.test.org/jaws"/>
        <property name="serviceName" value="SampleService"/>
        <property name="portName" value="SampleServicePort"/>
    </bean>
    Thanks, Claudio.
    Last edited by csanchez; Jan 24th, 2007, 03: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

    Comment


    • #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?

      Comment


      • #4
        Something like
        http://username:password@localhost:8...rviceBean?wsdl
        should do the trick.

        Comment

        Working...
        X