Class KeyIdentifier


  • public class KeyIdentifier
    extends Object
    This class KeyIdentifier can be be used to insert the key identifier information into SecurityTokenReference.
    • Constructor Detail

      • KeyIdentifier

        public KeyIdentifier​(String valueType,
                             String encodingType,
                             String value)
        Constructor.
        Parameters:
        valueType - the value type of the key value.
        encodingType - the encoding type of the key value
        value - the key identifier value.
    • Method Detail

      • getValueType

        public String getValueType()
        Returns the value type set in the key identifier.
        Returns:
        the value type.
      • getEncodingType

        public String getEncodingType()
        Returns the encoding type in the key identifier.
        Returns:
        the encoding type.
      • getReferenceValue

        public String getReferenceValue()
        Returns the key identifier reference value.
        Returns:
        the key identifier reference value.
      • getValue

        public String getValue()
        Return the value in the key identifier.
        Returns:
        the value in the keu identifier.
      • setValue

        public void setValue​(String value)
        Sets the value in the key identifier.
        Parameters:
        value - the value in the key identifier.
      • getId

        public String getId()
        Returns the id.
        Returns:
        the id.
      • getTokenElement

        public Element getTokenElement​(Document doc)
                                throws SecurityException
        Returns the security token that is referenced via the key identifier.
        Parameters:
        doc - the SOAPMessage XML document
        Returns:
        the security token element matches with the assertion.
        Throws:
        SecurityException - if there is a failure.
      • addToParent

        public void addToParent​(Element parent)
                         throws SecurityException
        Adds the key identifier to the parent element.
        Parameters:
        parent - the parent node that keyidentifier needs to be added.
        Throws:
        SecurityException - if there is a failure.