Class WSDocInfo

java.lang.Object
org.apache.wss4j.dom.WSDocInfo

public class WSDocInfo extends Object
  • Constructor Details

    • WSDocInfo

      public WSDocInfo(Document doc)
  • Method Details

    • clear

      public void clear()
      Clears the data stored in this object
    • addTokenElement

      public void addTokenElement(Element element) throws WSSecurityException
      Store a token element for later retrieval. Before storing the token, we check for a previously processed token with the same (wsu/SAML) Id.
      Parameters:
      element - is the token element to store
      Throws:
      WSSecurityException
    • addTokenElement

      public void addTokenElement(Element element, boolean checkMultipleElements) throws WSSecurityException
      Store a token element for later retrieval. Before storing the token, we check for a previously processed token with the same (wsu/SAML) Id.
      Parameters:
      element - is the token element to store
      checkMultipleElements - check for a previously stored element with the same Id.
      Throws:
      WSSecurityException
    • getTokenElement

      public Element getTokenElement(String uri)
      Get a token Element for the given Id. The Id can be either a wsu:Id or a SAML AssertionID/ID.
      Parameters:
      uri - is the (relative) uri of the id
      Returns:
      the token element or null if nothing found
    • setTokensOnContext

      public void setTokensOnContext(DOMCryptoContext context)
      Set all stored tokens on the DOMCryptoContext argument
      Parameters:
      context -
    • setTokenOnContext

      public void setTokenOnContext(String uri, DOMCryptoContext context)
    • addResult

      public void addResult(WSSecurityEngineResult result)
      Store a WSSecurityEngineResult for later retrieval.
      Parameters:
      result - is the WSSecurityEngineResult to store
    • getResults

      public List<WSSecurityEngineResult> getResults()
      Get a copy of the security results list. Modifying the subsequent list does not change the internal results list.
    • getActionResults

      public Map<Integer,List<WSSecurityEngineResult>> getActionResults()
      Return a copy of the map between security actions + results. Modifying the subsequent map does not change the internal map.
    • getResult

      public WSSecurityEngineResult getResult(String uri)
      Get a WSSecurityEngineResult for the given Id.
      Parameters:
      uri - is the (relative) uri of the id
      Returns:
      the WSSecurityEngineResult or null if nothing found
    • getResultsByTag

      public List<WSSecurityEngineResult> getResultsByTag(Integer tag)
      Get a unmodifiable list of WSSecurityEngineResults of the given Integer tag
    • hasResult

      public boolean hasResult(Integer tag, String uri)
      See whether we have a WSSecurityEngineResult of the given Integer tag for the given Id
    • getCrypto

      public Crypto getCrypto()
      Returns:
      the signature crypto class used to process the signature/verify
    • getDocument

      public Document getDocument()
      Returns:
      the document
    • setCrypto

      public void setCrypto(Crypto crypto)
      Parameters:
      crypto - is the signature crypto class used to process signature/verify
    • setCallbackLookup

      public void setCallbackLookup(CallbackLookup callbackLookup)
      Parameters:
      callbackLookup - The CallbackLookup object to retrieve elements
    • getCallbackLookup

      public CallbackLookup getCallbackLookup()
      Returns:
      the CallbackLookup object to retrieve elements
    • getSecurityHeader

      public Element getSecurityHeader()
      Returns:
      the wsse header being processed
    • setSecurityHeader

      public void setSecurityHeader(Element securityHeader)
      Sets the wsse header being processed
      Parameters:
      securityHeader -