com.ibm.websphere.wssecurity.wssapi

Interface WSSGenerationContext


  1. public interface WSSGenerationContext
This interface stores the components for generating the SOAP message, such as signature, encryption, attached security token, and attached time stamp.
  1. Generate the wssfactory instance.
  2. Generate the wssGenerationContext instance.
  3. Create the components, such as WSSSignature, WSSEncryption, SecurityToken, WSSTimestamp object.
  4. Set the components into the wssGenerationContext object.
  5. Invoke wssGenerationContext.process() method.

Method Summary

Modifier and Type Method and Description
  1. void
add(java.util.HashMap<java.lang.Object,java.lang.Object> customProperties)
Adds the custom properties HashMap object
  1. void
add(SecurityToken token)
Adds the SecurityToken object in order to attach the security token to the SOAP message.
  1. void
add(WSSEncryption enc)
Adds the WSSEncyption object in order to encrypt the element in the SOAP message.
  1. void
add(WSSSignature sig)
Adds the WSSSignature object in order to sign the element in the SOAP message.
  1. void
add(WSSTimestamp ts)
Adds the WSSTimestamp object in order to attach the time stamp to the SOAP message.
  1. void
process(java.lang.Object messageContext)
The WS-Security element is generated after this method is called.

Method Detail

add

  1. void add(WSSSignature sig)
Adds the WSSSignature object in order to sign the element in the SOAP message.
Parameters:
sig - signature object

add

  1. void add(WSSEncryption enc)
Adds the WSSEncyption object in order to encrypt the element in the SOAP message.
Parameters:
enc - encryption object

add

  1. void add(SecurityToken token)
Adds the SecurityToken object in order to attach the security token to the SOAP message.
Parameters:
token - security token object

add

  1. void add(WSSTimestamp ts)
Adds the WSSTimestamp object in order to attach the time stamp to the SOAP message.
Parameters:
ts - time stamp object

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 generated after this method is called.
Parameters:
messageContext - SOAP message context
Throws:
WSSException - if an unexcepted error occurs in processing