Class FSAuthnResponse
- java.lang.Object
-
- com.sun.identity.saml.protocol.AbstractResponse
-
- com.sun.identity.saml.protocol.Response
-
- com.sun.identity.federation.message.FSAuthnResponse
-
@Deprecated public class FSAuthnResponse extends Response
Deprecated.since 12.0.0The classFSAuthnResponsecreates and parses the Liberty Response. This class extends theSAMLResponse.
-
-
Field Summary
Fields Modifier and Type Field Description protected StringconsentURIDeprecated.protected ElementdomElementDeprecated.protected StringidDeprecated.protected intminorVersionDeprecated.protected StringrelayStateDeprecated.-
Fields inherited from class com.sun.identity.saml.protocol.Response
assertions, issuer, signatureString, status, xmlString
-
Fields inherited from class com.sun.identity.saml.protocol.AbstractResponse
inResponseTo, issueInstant, majorVersion, recipient, responseID, signature, signed, valid, validationDone
-
-
Constructor Summary
Constructors Constructor Description FSAuthnResponse(String responseID, String inResponseTo, Status status, List contents, String relayState)Deprecated.Constructor to createFSAuthnResponseobject.FSAuthnResponse(Element root)Deprecated.Constructor createsFSAuthnResponseobject from Document Element.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description StringgetConsentURI()Deprecated.Returns the value of theconsentattribute.ElementgetDOMElement()Deprecated.Returns the Document Element for this object.StringgetID()Deprecated.Returns the value of theidattribute.intgetMinorVersion()Deprecated.Returns the valueMinorVersionattribute.StringgetProviderId()Deprecated.Returns theProviderIDattribute value.StringgetRelayState()Deprecated.Returns theRelayStateattribute in the Response.StringgetSignatureString()Deprecated.Returns the Signature string.StringgetSignedXMLString()Deprecated.Returns a signed XML Representation of this object.static FSAuthnResponseparseAuthnResponseXML(String xml)Deprecated.CreatesFSAuthnResponseobject from XML Schema.static FSAuthnResponseparseBASE64EncodedString(String encodedRes)Deprecated.ReturnsFSAutnResponseobject by parsing aBase64encoding XML string.voidsetConsentURI(String consent)Deprecated.Sets the value of theconsentattribute.voidsetID(String id)Deprecated.Sets the value of theidattribute.voidsetMinorVersion(int version)Deprecated.Returns the value ofMajorVersionattribute.voidsetProviderId(String provId)Deprecated.Sets theProviderIDattribute value.booleansetSignature(Element elem)Deprecated.Sets theElementsignature.voidsignXML(String certAlias)Deprecated.Signs theResponse.StringtoBASE64EncodedString()Deprecated.Returns aBase64encoded string representing this object.StringtoXMLString()Deprecated.Returns the string representation of this object.StringtoXMLString(boolean includeNS, boolean declareNS)Deprecated.Returns a String representation of the <samlp:Response> element.StringtoXMLString(boolean includeNS, boolean declareNS, boolean includeHeader)Deprecated.Returns a String representation of the <samlp:Response> element.-
Methods inherited from class com.sun.identity.saml.protocol.Response
addAssertion, getAssertion, getStatus, isSignatureValid, parseXML, parseXML, setStatus, signXML, toString, toString, toString
-
Methods inherited from class com.sun.identity.saml.protocol.AbstractResponse
getInResponseTo, getIssueInstant, getMajorVersion, getRecipient, getResponseID, getSignature, isSigned, setInResponseTo, setIssueInstant, setMajorVersion, setRecipient, setResponseID
-
-
-
-
Constructor Detail
-
FSAuthnResponse
public FSAuthnResponse(String responseID, String inResponseTo, Status status, List contents, String relayState) throws SAMLException, FSMsgException
Deprecated.Constructor to createFSAuthnResponseobject.- Parameters:
responseID- value of theResponseIDattribute.inResponseTo- value of theinResponseToattribute.status- theStatusobject.contents- List of Assertions in the response. It could be null when there are no Assertions.relayState- value of theRelayStateattribute.- Throws:
FSMsgException- on error.SAMLException- on error.
-
FSAuthnResponse
public FSAuthnResponse(Element root) throws SAMLException, FSMsgException
Deprecated.Constructor createsFSAuthnResponseobject from Document Element.- Parameters:
root- the Document Element- Throws:
SAMLException- on error.FSMsgException- on error.
-
-
Method Detail
-
parseAuthnResponseXML
public static FSAuthnResponse parseAuthnResponseXML(String xml) throws SAMLException, FSMsgException
Deprecated.CreatesFSAuthnResponseobject from XML Schema.- Parameters:
xml- the XML Schema for this object.- Throws:
FSMsgException- on error.SAMLException
-
getID
public String getID()
Deprecated.Returns the value of theidattribute.- Returns:
- the value of
idattribute. - See Also:
setID(String)
-
setID
public void setID(String id)
Deprecated.Sets the value of theidattribute.- Parameters:
id- the new value ofidattribute.- See Also:
getID()
-
getProviderId
public String getProviderId()
Deprecated.Returns theProviderIDattribute value.- Returns:
- value of the
ProviderIDattribute. - See Also:
setProviderId(String)
-
setProviderId
public void setProviderId(String provId)
Deprecated.Sets theProviderIDattribute value.- Parameters:
provId- new value ofProviderIDattribute.- 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.
-
getMinorVersion
public int getMinorVersion()
Deprecated.Returns the valueMinorVersionattribute.- Overrides:
getMinorVersionin classAbstractResponse- Returns:
- the value
MinorVersionattribute. - See Also:
setMinorVersion(int)
-
setMinorVersion
public void setMinorVersion(int version)
Deprecated.Returns the value ofMajorVersionattribute.- Overrides:
setMinorVersionin classAbstractResponse- Parameters:
version- the value ofMajorVersionattribute.- See Also:
getMinorVersion()
-
getConsentURI
public String getConsentURI()
Deprecated.Returns the value of theconsentattribute.- Returns:
- value of
consentattribute. - See Also:
setConsentURI(String)
-
setConsentURI
public void setConsentURI(String consent)
Deprecated.Sets the value of theconsentattribute.- Parameters:
consent- new value ofconsentattribute.- 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 theRelayStateattribute in the Response.- Returns:
- the
RelayStateattribute 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 converteddeclareNS- : 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 converteddeclareNS- 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.ReturnsFSAutnResponseobject by parsing aBase64encoding XML string.- Parameters:
encodedRes- theBase64encoded string.- Returns:
FSAuthnResponseobject.- Throws:
FSMsgException- if there is an error parsing theBase64encoded string.SAMLException- if there is an error creating theFSAuthnResponseobject.
-
toBASE64EncodedString
public String toBASE64EncodedString() throws FSMsgException
Deprecated.Returns aBase64encoded string representing this object.- Returns:
- a
Base64encoded string representing this object. - Throws:
FSMsgException- if there is an error creating aBase64encoded string.
-
signXML
public void signXML(String certAlias) throws SAMLException
Deprecated.Signs theResponse.- Parameters:
certAlias- the Certificate Alias- Throws:
SAMLException- ifResponsecannot be signed.
-
setSignature
public boolean setSignature(Element elem)
Deprecated.Sets theElementsignature.- Overrides:
setSignaturein classResponse- Parameters:
elem- theElementobject- Returns:
- true if signature is set otherwise false
-
-