wood burning stoves 2.0*
The moose likes Web Services and the fly likes JAX-WS Authentication Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "JAX-WS Authentication" Watch "JAX-WS Authentication" New topic
Author

JAX-WS Authentication

Poornima Sharma
Ranch Hand

Joined: Sep 09, 2008
Posts: 114
Hi,

How can we create username password authentication in JAX-WS? I am using Axis2 with tomcat.

Thanks,


Poornima Sharma
SCJP 6.0
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39548
    
  27
That's the realm of WS-Security; Axis2 has the Rampart module that implements it.


Ping & DNS - updated with new look and Ping home screen widget
Poornima Sharma
Ranch Hand

Joined: Sep 09, 2008
Posts: 114
Hi Ulf,

Thanks for your answer. My only requirement is to create a callback method which can authenticate the username and password and add these two attributes in the header. Is rampart the only way of implementing it? Actually I am using JAX-WS with annotations, hence I was looking for something in annotation which can perform this task. (I am having problem implementing Axis2 1.5.4 and Rampart 1.5.1 with SSL layer.)

Please suggest.

Thanks
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39548
    
  27
There is no standard Java API for how WS-Security integrates with JAX-WS - each SOAP stack does it differently. But none I'm aware of uses annotations. And yes - Rampart is what you use for WS-Security along with Axis2.

You shouldn't be using SSL to secure web services - WS-Security provides encryption as well as authentication.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JAX-WS Authentication
 
Similar Threads
JAX-WS RI 2.1 Authantication
SOA and REST with JBOSS
How to get client IP in WebService ?
How to establish the mutual authentication using "client.cer" file
JAX-WS Authentication problem -javax.xml.ws.WebServiceException Response: '401: Unauthorized'