Class FSAuthnResponse


  • @Deprecated
    public class FSAuthnResponse
    extends Response
    Deprecated.
    since 12.0.0
    The class FSAuthnResponse creates and parses the Liberty Response. This class extends the SAML Response.
    • Field Detail

      • relayState

        protected String relayState
        Deprecated.
      • consentURI

        protected String consentURI
        Deprecated.
      • minorVersion

        protected int minorVersion
        Deprecated.
      • id

        protected String id
        Deprecated.
      • domElement

        protected Element domElement
        Deprecated.
    • Constructor Detail

      • FSAuthnResponse

        public FSAuthnResponse​(String responseID,
                               String inResponseTo,
                               Status status,
                               List contents,
                               String relayState)
                        throws SAMLException,
                               FSMsgException
        Deprecated.
        Constructor to create FSAuthnResponse object.
        Parameters:
        responseID - value of the ResponseID attribute.
        inResponseTo - value of the inResponseTo attribute.
        status - the Status object.
        contents - List of Assertions in the response. It could be null when there are no Assertions.
        relayState - value of the RelayState attribute.
        Throws:
        FSMsgException - on error.
        SAMLException - on error.
    • Method Detail

      • getID

        public String getID()
        Deprecated.
        Returns the value of the id attribute.
        Returns:
        the value of id attribute.
        See Also:
        setID(String)
      • setID

        public void setID​(String id)
        Deprecated.
        Sets the value of the id attribute.
        Parameters:
        id - the new value of id attribute.
        See Also:
        getID()
      • getProviderId

        public String getProviderId()
        Deprecated.
        Returns the ProviderID attribute value.
        Returns:
        value of the ProviderID attribute.
        See Also:
        setProviderId(String)
      • setProviderId

        public void setProviderId​(String provId)
        Deprecated.
        Sets the ProviderID attribute value.
        Parameters:
        provId - new value of ProviderID attribute.
        See Also:
        getProviderId()
      • getSignedXMLString

        public String getSignedXMLString()
        Deprecated.
        Returns a signed XML Representation of this object.
        Returns:
        a signed XML Representation of this object.
      • getSignatureString

        public String getSignatureString()
        Deprecated.
        Returns the Signature string.
        Returns:
        the Signature string.
      • setMinorVersion

        public void setMinorVersion​(int version)
        Deprecated.
        Returns the value of MajorVersion attribute.
        Overrides:
        setMinorVersion in class AbstractResponse
        Parameters:
        version - the value of MajorVersion attribute.
        See Also:
        getMinorVersion()
      • getConsentURI

        public String getConsentURI()
        Deprecated.
        Returns the value of the consent attribute.
        Returns:
        value of consent attribute.
        See Also:
        setConsentURI(String)
      • setConsentURI

        public void setConsentURI​(String consent)
        Deprecated.
        Sets the value of the consent attribute.
        Parameters:
        consent - new value of consent attribute.
        See Also:
        getConsentURI()
      • getDOMElement

        public Element getDOMElement()
        Deprecated.
        Returns the Document Element for this object.
        Returns:
        the Document Element for this object.
      • getRelayState

        public String getRelayState()
        Deprecated.
        Returns the RelayState attribute in the Response.
        Returns:
        the RelayState attribute in the Response.
      • toXMLString

        public String toXMLString()
                           throws FSMsgException
        Deprecated.
        Returns the string representation of this object. This method translates the response to an XML document string based on the Response schema described above.
        Returns:
        An XML String representing the response. NOTE: this is a complete SAML response xml string with ResponseID, MajorVersion, etc.
        Throws:
        FSMsgException
      • toXMLString

        public String toXMLString​(boolean includeNS,
                                  boolean declareNS)
                           throws FSMsgException
        Deprecated.
        Returns a String representation of the <samlp:Response> element.
        Parameters:
        includeNS - : Determines whether or not the namespace qualifier is prepended to the Element when converted
        declareNS - : Determines whether or not the namespace is declared within the Element.
        Returns:
        A string containing the valid XML for this element
        Throws:
        FSMsgException
      • toXMLString

        public String toXMLString​(boolean includeNS,
                                  boolean declareNS,
                                  boolean includeHeader)
                           throws FSMsgException
        Deprecated.
        Returns a String representation of the <samlp:Response> element.
        Parameters:
        includeNS - Determines whether or not the namespace qualifier is prepended to the Element when converted
        declareNS - Determines whether or not the namespace is declared within the Element.
        includeHeader - Determines whether the output include the xml declaration header.
        Returns:
        A string containing the valid XML for this element
        Throws:
        FSMsgException
      • parseBASE64EncodedString

        public static FSAuthnResponse parseBASE64EncodedString​(String encodedRes)
                                                        throws FSMsgException,
                                                               SAMLException
        Deprecated.
        Returns FSAutnResponse object by parsing a Base64 encoding XML string.
        Parameters:
        encodedRes - the Base64 encoded string.
        Returns:
        FSAuthnResponse object.
        Throws:
        FSMsgException - if there is an error parsing the Base64 encoded string.
        SAMLException - if there is an error creating the FSAuthnResponse object.
      • toBASE64EncodedString

        public String toBASE64EncodedString()
                                     throws FSMsgException
        Deprecated.
        Returns a Base64 encoded string representing this object.
        Returns:
        a Base64 encoded string representing this object.
        Throws:
        FSMsgException - if there is an error creating a Base64 encoded string.
      • signXML

        public void signXML​(String certAlias)
                     throws SAMLException
        Deprecated.
        Signs the Response.
        Parameters:
        certAlias - the Certificate Alias
        Throws:
        SAMLException - if Response cannot be signed.
      • setSignature

        public boolean setSignature​(Element elem)
        Deprecated.
        Sets the Element signature.
        Overrides:
        setSignature in class Response
        Parameters:
        elem - the Element object
        Returns:
        true if signature is set otherwise false