• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Devaka Cooray
  • Ron McLeod
  • paul wheaton
Saloon Keepers:
  • Tim Moores
  • Piet Souris
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Frits Walraven
  • Scott Selikoff

Need to know steps to access web service

 
Ranch Hand
Posts: 541
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We have few web services developed in ASP.NET and I need to access them using AXIS2 client. When I open the WSDL in browser, I need to enter username and password before I see the WSDL. I assume that means it is under HTTPS Basic authentication. Now can someone tell me steps to create AXIS2 client for it? How to pass basic authentication?
 
Rancher
Posts: 43028
76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Just about any SOAP implementation has tools that will create Java client code for you. Generally you would point them at the WSDL (either online or a local file) to do that.
 
Saurabh Pillai
Ranch Hand
Posts: 541
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I tried WSDL2Java tool.

I am getting this exception,
 
Ulf Dittmer
Rancher
Posts: 43028
76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
See the last question in the https://coderanch.com/how-to/java/SecurityFaq.
 
Saurabh Pillai
Ranch Hand
Posts: 541
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The server is using GoDaddy certificate. I have also added certificate to my local Java installation using this.

I want to repeat one thing that I can't access the WSDL in point "directly", it means, when I type that URL, browser prompts me for username and password. And then I can see the WSDL. But I never entered them anywhere while generating client using WSDL2Java tool. I think somewhere it should be mentioned.

I also looked at the definition of WSDL2Java tool but there is no parameter for username/password.

ty
 
Ranch Hand
Posts: 1514
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Does the WSDL describe the security header? If so, then doesn't JAX-WS generate the code to pass the security credentials?
 
Is that a spider in your hair? Here, threaten it with this tiny ad:
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic