You are viewing a plain text version of this content. The canonical link for it is here.
Posted to wss4j-dev@ws.apache.org by Jean-Noel Colin <jn...@oxys.be> on 2006/02/20 15:42:59 UTC

How to programmatically set server-side handler properties

Hi
 
I would like to know how I can programmatically set server side handler
properties.
 
I have a web service that responds to requests (unsigned and unencrypted)
with encrypted responses (I know the scenario looks strange, but it is for
student's practice). Note that responses are not encrypted in all cases.
 
I'm wondering how I can programmatically set the "encryptionUser" property
of the WSDoAllSender handler to deal with different clients. I'm been
searching through the doc and the web without finding a proper solution. I
know I could define the handler programmatically, or create my own handler
and call the signing methods. But I would like to achieve something like
what's done in the client:
 
 PingServiceLocator service = new PingServiceLocator();
    ...
PingPort port = (PingPort) service.getPing1();
port._setProperty(UsernameToken.PASSWORD_TYPE, WSConstants.PASSWORD_TEXT);
port._setProperty(WSHandlerConstants.USER, "werner");

Thanks for your help
 
Jean-Noel Colin