Thanks again, Xinjun.
 
Very valuable hint.
 
I used the WSS4J tutorial ( http://ws.apache.org/wss4j/axis.html ) and example page ( http://ws.apache.org/wss4j/package.html  ), but I could not get the client working.
 
After I configured the WSDoAllReceiver, it requires the credentials. OK!
 
But I changed my client to add the UsernameToken, but it does not add it to the SOAP request.
 
My code is like this:
 
MyServiceLocator serv = new MyServiceLocator();
MyService port = serv.getMyService();
 
Stub stub = (Stub) port;
stub._setProperty(UsernameToken.PASSWORD_TYPE, WSConstants.PASSWORD_TEXT);
stub._setProperty(WSHandlerConstants.USER, "werner");
stub._setProperty(WSHandlerConstants.PW_CALLBACK_REF, new PWCallback());
 
port.myMethod( someParam );
 
 
The SOAP is still the same, with no UsernameToken. What I am doing worng??
 
Thanks

 
On 4/6/06, Xinjun Chen <[EMAIL PROTECTED]> wrote:
Hi Daniel,
To be specific, I tried wss4j using the Axis 1.3 library. The
following article may be useful to you.
http://www.devx.com/Java/Article/28816/0/page/1
The author uses Axis 1.x library.

Regards,
Xinjun

Reply via email to