com.ibm.websphere.wssecurity.wssapi

Interface WSSConsumingContext


  1. public interface WSSConsumingContext
This interface stores the components for consuming of WS-Security, such as verification, decryption, the security token and the time stamp. When the validate() method is called, all of components are validated.
  1. Generate the wssfactory instance.
  2. Generate the wssConsumingContext instance.
  3. Create the components, such as WSSVerification, WSSDecryption object, required information to validate the securitytoken, and the keyword of the time stamp.
  4. Set the components into the wssConsumingContext object.
  5. Invoke wssConsumingContext.process() method.

Field Summary

Modifier and Type Field and Description
  1. static
  2. int
TIMESTAMP
The keyword for the creation and expiration time stamp information.

Method Summary

Modifier and Type Method and Description
  1. void
add(java.lang.Class tokenClass,javax.security.auth.callback.CallbackHandler callbackHandler)
Sets the security token information in order to validate the security token in the receiving SOAP message.
  1. void
add(java.lang.Class tokenClass,javax.security.auth.callback.CallbackHandler callbackHandler,java.lang.String loginConfigName)
Adds the security token information in order to validate the security token in the receiving SOAP message.
  1. void
add(java.util.HashMap<java.lang.Object,java.lang.Object> customProperties)
Adds the custom properties HashMap object
  1. void
add(int keyword)
Sets the keyword of the TIMESTAMP in case of requiring the time stamp in the receiving SOAP message.
  1. void
add(WSSDecryption decryption)
Adds the WSSDecryption object in order to decrypt the element in the receiving SOAP message.
  1. void
add(WSSVerification verification)
Adds the WSSVerification object in order to verify the element in the receiving SOAP message.
  1. void
process(java.lang.Object messageContext)
The WS-Security element is consumed after this method is called.

Field Detail

TIMESTAMP

  1. static final int TIMESTAMP
The keyword for the creation and expiration time stamp information.
See Also:

Method Detail

add

  1. void add(WSSVerification verification)
Adds the WSSVerification object in order to verify the element in the receiving SOAP message.
Parameters:
verification - verification object

add

  1. void add(WSSDecryption decryption)
Adds the WSSDecryption object in order to decrypt the element in the receiving SOAP message.
Parameters:
decryption - decryption object

add

  1. void add(java.lang.Class tokenClass,
  2. javax.security.auth.callback.CallbackHandler callbackHandler,
  3. java.lang.String loginConfigName)
  4. throws WSSException
Adds the security token information in order to validate the security token in the receiving SOAP message.
Parameters:
tokenClass - class of the security token
callbackHandler - callback handler object which the user implements javax.security.auth.callback.CallbackHandler
loginConfigName - the name of the JAAS login configuration
Throws:
WSSException - if the arguments are not valid

add

  1. void add(java.lang.Class tokenClass,
  2. javax.security.auth.callback.CallbackHandler callbackHandler)
  3. throws WSSException
Sets the security token information in order to validate the security token in the receiving SOAP message.
Parameters:
tokenClass - class of the security token
callbackHandler - callback handler object which the user implements javax.security.auth.callback.CallbackHandler
Throws:
WSSException - if the arguments are not valid

add

  1. void add(int keyword)
  2. throws WSSException
Sets the keyword of the TIMESTAMP in case of requiring the time stamp in the receiving SOAP message.
Parameters:
keyword -
Throws:
WSSException - if the keyword is not valid

add

  1. void add(java.util.HashMap<java.lang.Object,java.lang.Object> customProperties)
Adds the custom properties HashMap object

process

  1. void process(java.lang.Object messageContext)
  2. throws WSSException
The WS-Security element is consumed after this method is called.
Parameters:
messageContext - SOAP message context
Throws:
WSSException - if an unexcepted error occurs in processing