Rampart works with Axis2 not Axis 1.x.

Thanks,
Ruchith

On 3/22/07, John Kristian <[EMAIL PROTECTED]> wrote:
Rampart can do this, but not easily.  Search this mailing list for
'Rampart' to find some problems.
http://ws.apache.org/axis2/modules/rampart/1_0/security-module.html

I sincerely hope someone knows a better way.

- John Kristian

-----Original Message-----
From: herbison [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 21, 2007 12:46 PM
To: axis-user@ws.apache.org
Subject: Axis 1.4 Security using UsernameToken

I'm tring to access a .NET service, using code generated by wsdl2java,
where
I have to set the UsernameToken fields Username and Password in the soap
header.  How is this done?!!  I've been going around in circles all
morning
and nothing seems to get me any closer in setting the soap fields.  This
is
what the client looks like now:

String id="user";
String key="password";
PWCallback pwCallback = new PWCallback();
pwCallback.setUsername(id);
pwCallback.setPassword(key);

ClaimProcessorLocator loc = new ClaimProcessorLocator();
Remote remote = loc.getPort( Claim.class);
Stub axisPort = (Stub)remote;
axisPort._setProperty(UsernameToken.PASSWORD_TYPE,
WSConstants.PASSWORD_DIGEST);
axisPort._setProperty(WSHandlerConstants.USER, id);
axisPort._setProperty(WSHandlerConstants.PW_CALLBACK_REF, pwCallback);

IClaim iclaim = (IClaim) loc.getBasicHttpBinding_IClaim();
Claim claim = iclaim.getClaim();

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
www.ruchith.org
www.wso2.org

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to