public class UsernameTokenConsumer extends java.lang.Object implements TokenConsumerComponent
Subject of the current thread for the later use. It also creates a
WSSAuthToken for later use
in the WebSphere login process by WSSConsumerComponent.| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
_DISABLE_REGISTRY_CHECK |
| Constructor and Description |
|---|
UsernameTokenConsumer() |
| Modifier and Type | Method and Description |
|---|---|
protected static java.util.Date |
checkNonce(org.w3c.dom.Element target,
TokenConsumerConfig config,
java.lang.String nsWsse,
java.lang.String nsWsu,
com.ibm.xml.soapsec.token.NonceManager nmanager)
Checks the timestamp and nonce in the Username element.
|
void |
init(java.util.Map map)
Initializes this consumer with a
TokenConsumerConfig object which is passed
in by the map parameter. |
void |
invoke(org.w3c.dom.Node target,
java.util.Map context)
Consumes a username token in a SOAP message.
|
protected static UsernameToken |
invokeLoginModule(TokenConsumerConfig config,
java.lang.String username,
char[] password,
com.ibm.wsspi.webservices.rpc.handler.soap.SOAPMessageContext messageContext,
java.util.Map context,
boolean delayLogin)
Invokes LoginModule through LoignContext.login() to create and validate a certificate object
|
public static final java.lang.String _DISABLE_REGISTRY_CHECK
public void init(java.util.Map map)
throws SoapSecurityException
TokenConsumerConfig object which is passed
in by the map parameter.init in interface com.ibm.ws.webservices.wssecurity.WSSComponentinit in interface Initializablemap - A Map object which contains
name-value pairs.
These pairs includes a configuration object and
<Property> elements in the
configuration XMI files. In the map, the TokenConsumerConfig object
is stored with a key of TokenConsumerConfig.CONFIG_KEY.SoapSecurityException - When there is a problem initializing the consumerInitializable.init(java.util.Map),
TokenConsumerConfigpublic void invoke(org.w3c.dom.Node target,
java.util.Map context)
throws SoapSecurityException
UsernameLoginModule.
The login module will create the UsernameToken object and put it into the
Subject of the current thread. It also creates a WSSAuthToken
if authentication is required with this token.
Note: We do not support "#PassowrdDigest" because WebSphere runtime is not capable of accepting a digest value of password to return the login result.
invoke in interface com.ibm.ws.webservices.wssecurity.WSSConsumerComponenttarget - The element to be consumed or the
Document objectcontext - A Map object which contains
necessary name-value pairs, such as a Subject object.SoapSecurityException - When there is a problem during consuming the username tokenWSSConsumerComponent.invoke(org.w3c.dom.Node, java.util.Map)protected static UsernameToken invokeLoginModule(TokenConsumerConfig config, java.lang.String username, char[] password, com.ibm.wsspi.webservices.rpc.handler.soap.SOAPMessageContext messageContext, java.util.Map context, boolean delayLogin) throws SoapSecurityException
SoapSecurityExceptionprotected static java.util.Date checkNonce(org.w3c.dom.Element target,
TokenConsumerConfig config,
java.lang.String nsWsse,
java.lang.String nsWsu,
com.ibm.xml.soapsec.token.NonceManager nmanager)
throws SoapSecurityException
SoapSecurityException