|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sun.identity.saml.protocol.AbstractRequest com.sun.identity.federation.message.FSAuthnRequest
public class FSAuthnRequest
The class FSAuthnRequest
is used to create , parse
AuthnRequest
object.
Field Summary | |
---|---|
protected String |
affiliationID
|
protected String |
assertionConsumerServiceID
|
protected String |
authContextCompType
|
protected String |
consentURI
|
protected String |
id
|
protected int |
minorVersion
|
protected FSScoping |
scoping
|
protected String |
signatureString
|
protected String |
xmlString
|
Fields inherited from class com.sun.identity.saml.protocol.AbstractRequest |
---|
issueInstant, majorVersion, requestID, respondWiths, signature, signed, valid |
Constructor Summary | |
---|---|
FSAuthnRequest()
Default AuthnRequest construtor |
|
FSAuthnRequest(Element root)
Constructor to create FSAuthnRequest object. |
|
FSAuthnRequest(String requestId,
List respondWiths,
String providerID,
boolean forceAuthn,
boolean isPassive,
boolean fed,
String nameIDPolicy,
String protocolProf,
RequestAuthnContext authnCxt,
String relaySt,
String authContextCompType)
Constructor to create FSAuthnRequest object. |
Method Summary | |
---|---|
String |
getAffiliationID()
Returns the Affliation Identifier. |
String |
getAssertionConsumerServiceID()
Returns the Assertion Consumer Service Identifier. |
String |
getAuthContextCompType()
Returns the value of AuthContext Comparison attribute. |
RequestAuthnContext |
getAuthnContext()
Returns the RequestedAuthnContext object. |
String |
getConsent()
Returns the value of consent attribute. |
List |
getExtensions()
Returns a list of Extension objects. |
boolean |
getFederate()
Returns the value of the Federate attribute. |
boolean |
getForceAuthn()
Returns the value of Force Authentication attribute. |
String |
getID()
Returns the value of id attribute. |
boolean |
getIsPassive()
Returns the value of the isPassive attribute. |
int |
getMinorVersion()
Returns the value of the MinorVersion attribute. |
String |
getNameIDPolicy()
Returns the NameIDPolicy object. |
String |
getProtocolProfile()
Returns the value of ProtocolProfile |
String |
getProviderId()
Returns the value of ProviderID attribute. |
String |
getRelayState()
Returns the value of RelayState attribute. |
FSScoping |
getScoping()
Returns the FSScoping object. |
String |
getSignatureString()
Returns the signature string. |
String |
getSignedXMLString()
Returns Signed XML String representation of this object. |
static FSAuthnRequest |
parseBASE64EncodedString(String encodedReq)
Returns FSAuthnRequest object. |
static FSAuthnRequest |
parseURLEncodedRequest(HttpServletRequest request)
Returns FSAuthnRequest object. |
static FSAuthnRequest |
parseXML(String xml)
Returns the FSAuthnRequest object. |
void |
setAffiliationID(String affiliationID)
Sets the Affiliation Identifier. |
void |
setAssertionConsumerServiceID(String assertionConsumerServiceID)
Sets the Assertion Consumer Service Identifier. |
void |
setAuthContextCompType(String authType)
Sets the value of AuthContext Comparison attribute. |
void |
setAuthnContext(RequestAuthnContext authnCxt)
Sets the RequestedAuthnContext object. |
void |
setConsent(String consentURI)
Sets the value of consent attribute. |
void |
setExtensions(List extensions)
Sets Extension objects. |
void |
setFederate(boolean fed)
Sets the value of the Federate attribute. |
void |
setForceAuthn(boolean forceAuthn)
Sets the value of Force Authentication attribute. |
void |
setID(String id)
Sets the value of id attribute. |
void |
setIsPassive(boolean isPassive)
Sets the value of the IsPassive attribute. |
void |
setMinorVersion(int version)
Sets the value of the MinorVersion attribute. |
void |
setNameIDPolicy(String nameIDPolicy)
Sets the NameIDPolicy object. |
void |
setProtocolProfile(String protocolProf)
Sets the value of ProtocolProfile |
void |
setProviderId(String provId)
Sets the value of ProviderID attribute. |
void |
setRelayState(String relaySt)
Set the value of RelayState attribute. |
void |
setScoping(FSScoping scoping)
Sets the FSScoping object. |
boolean |
setSignature(Element elem)
Sets the Signature of the Element passed. |
void |
signXML()
Unsupported Method. |
void |
signXML(String certAlias)
Signs the Request. |
String |
toBASE64EncodedString()
Returns a Base64 Encoded String. |
String |
toURLEncodedQueryString()
Returns an URL Encoded Query String. |
String |
toXMLString()
This method translates the request to an XML document String based on the Request schema described above. |
String |
toXMLString(boolean includeNS,
boolean declareNS)
Creates a String representation of the <lib:AuthnRequest> element. |
String |
toXMLString(boolean includeNS,
boolean declareNS,
boolean includeHeader)
Creates a String representation of the <lib:AuthnRequest> element. |
Methods inherited from class com.sun.identity.saml.protocol.AbstractRequest |
---|
addRespondWith, getIssueInstant, getMajorVersion, getRequestID, getRespondWith, getSignature, isSignatureValid, isSigned, setIssueInstant, setMajorVersion, setRequestID |
Field Detail |
---|
protected String xmlString
protected String signatureString
protected String authContextCompType
protected String id
protected String assertionConsumerServiceID
protected String consentURI
protected String affiliationID
protected int minorVersion
protected FSScoping scoping
Constructor Detail |
---|
public FSAuthnRequest()
public FSAuthnRequest(String requestId, List respondWiths, String providerID, boolean forceAuthn, boolean isPassive, boolean fed, String nameIDPolicy, String protocolProf, RequestAuthnContext authnCxt, String relaySt, String authContextCompType) throws FSMsgException
FSAuthnRequest
object.
requestId
- the request identifier.respondWiths
- List of respond withs attributes.providerID
- provider id of the requesting provider.forceAuthn
- Force Authentication boolean value.isPassive
- attribute for IDP to be passive or active.fed
- attribute to distingush this request for Federation or SSOnameIDPolicy
- Name ID Policy for this request, possible values
are "none", "onetime", "federated", "any".protocolProf
- ProtocolProfile used for the SSO.authnCxt
- Authentication Context used for the SSO.relaySt
- Relay State i.e. original URL to be redirected after SSO.authContextCompType
- AuthContext comparison type.
FSMsgException
- on error.
FSMsgException
public FSAuthnRequest(Element root) throws FSMsgException
FSAuthnRequest
object.
root
- the Document Element object.
FSMsgException
- on error.
FSMsgException
Method Detail |
---|
public String toXMLString() throws FSMsgException
FSMsgException
- if there is an error.public String toXMLString(boolean includeNS, boolean declareNS) throws FSMsgException
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.
FSMsgException
- if there is an error.public String toXMLString(boolean includeNS, boolean declareNS, boolean includeHeader) throws FSMsgException
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.
FSMsgException
- if there is an error.public static FSAuthnRequest parseXML(String xml) throws FSMsgException
FSAuthnRequest
object.
xml
- the XML string.
FSAuthnRequest
object.
FSMsgException
- if there is
error creating the object.public String getSignedXMLString()
public String getSignatureString()
public List getExtensions()
Extension
objects.
Each entry of the list is a Extension
object.
Extension
elements.FSAuthnRequest.setExtensions(List)
public void setExtensions(List extensions)
Extension
objects.
Each entry of the list is a Extension
object.
extensions
- a list of Extension
objects.FSAuthnRequest.getExtensions()
public boolean getForceAuthn()
public void setForceAuthn(boolean forceAuthn)
forceAuthn
- value of Force Authentication attribute.public boolean getIsPassive()
isPassive
attribute.
isPassive
attribute.public void setIsPassive(boolean isPassive)
IsPassive
attribute.
isPassive
- value of isPassive
attribute.public boolean getFederate()
Federate
attribute.
Federate
attribute.public void setFederate(boolean fed)
Federate
attribute.
fed
- the value of the Federate
attribute.public String getNameIDPolicy()
NameIDPolicy
object.
NameIDPolicy
object.FSAuthnRequest.setNameIDPolicy(String)
public void setNameIDPolicy(String nameIDPolicy)
NameIDPolicy
object.
nameIDPolicy
- the new NameIDPolicy
object.FSAuthnRequest.getNameIDPolicy()
public String getProtocolProfile()
ProtocolProfile attribute.
- Returns:
- the value of
ProtocolProfile attribute.- See Also:
FSAuthnRequest.setProtocolProfile(String)
public void setProtocolProfile(String protocolProf)
ProtocolProfile attribute.
- Parameters:
protocolProf
- the value of ProtocolProfile attribute.- See Also:
FSAuthnRequest.getProtocolProfile()
public String getRelayState()
FSAuthnRequest.setRelayState(String)
public void setRelayState(String relaySt)
relaySt
- the value of RelayState attribute.FSAuthnRequest.getRelayState()
public RequestAuthnContext getAuthnContext()
RequestedAuthnContext
object.
RequestedAuthnContext
object.FSAuthnRequest.setAuthnContext(RequestAuthnContext)
public void setAuthnContext(RequestAuthnContext authnCxt)
RequestedAuthnContext
object.
authnCxt
- the RequestAuthnContext
object.FSAuthnRequest.getAuthnContext()
public String getProviderId()
ProviderID
attribute.
ProviderID
attribute.FSAuthnRequest.setProviderId(String).
public void setProviderId(String provId)
ProviderID
attribute.
provId
- the value of ProviderID
attribute.FSAuthnRequest.getProviderId()
public String getAuthContextCompType()
FSAuthnRequest.setAuthContextCompType(String)
public void setAuthContextCompType(String authType)
authType
- he value of AuthContext Comparison attribute.FSAuthnRequest.getAuthContextCompType()
public String getID()
id
attribute.
id
attribute.FSAuthnRequest.setID(String)
public void setID(String id)
id
attribute.
id
- the value of id
attribute.FSAuthnRequest.getID()
public int getMinorVersion()
MinorVersion
attribute.
getMinorVersion
in class AbstractRequest
MinorVersion
attribute.FSAuthnRequest.setMinorVersion(int)
public void setMinorVersion(int version)
MinorVersion
attribute.
setMinorVersion
in class AbstractRequest
version
- the value of the MinorVersion
attribute.FSAuthnRequest.getMinorVersion()
public String getAffiliationID()
FSAuthnRequest.setAffiliationID(String)
public void setAffiliationID(String affiliationID)
affiliationID
- the Affiliation Identifier.FSAuthnRequest.getAffiliationID()
public String getAssertionConsumerServiceID()
FSAuthnRequest.setAssertionConsumerServiceID(String)
public void setAssertionConsumerServiceID(String assertionConsumerServiceID)
assertionConsumerServiceID
- the Assertion Consumer
Service Identifier.FSAuthnRequest.getAssertionConsumerServiceID()
public String getConsent()
consent
attribute.
consent
attribute.FSAuthnRequest.setConsent(String)
public void setConsent(String consentURI)
consent
attribute.
consentURI
- the value of consent
attribute.FSAuthnRequest.getConsent()
public void setScoping(FSScoping scoping)
FSScoping
object.
scoping
- the FSScoping
object.FSAuthnRequest.getScoping()
public FSScoping getScoping()
FSScoping
object.
FSScoping
object.FSAuthnRequest.setScoping(FSScoping)
public String toURLEncodedQueryString() throws FSMsgException
FSMsgException
- if there is an error.public String toBASE64EncodedString() throws FSMsgException
FSMsgException
- if there is an error encoding
the string.public static FSAuthnRequest parseURLEncodedRequest(HttpServletRequest request) throws FSMsgException
FSAuthnRequest
object. The
object is creating by parsing the HttpServletRequest
object.
request
- the HttpServletRequest
object.
FSMsgException
- if there is an error
creating FSAuthnRequest
object.public static FSAuthnRequest parseBASE64EncodedString(String encodedReq) throws FSMsgException
FSAuthnRequest
object. The object
is created by parsing an Base64 encode authentication
request string.
encodedReq
- the encode string
FSMsgException
- if there is an error
creating FSAuthnRequest
object.public void signXML(String certAlias) throws SAMLException
certAlias
- the Certificate Alias.
XMLSignatureException
- if FSAuthnRequest
cannot be signed.
SAMLException
public void signXML() throws SAMLException
signXML
in class AbstractRequest
SAMLException
- If could not sign the object.public boolean setSignature(Element elem)
setSignature
in class AbstractRequest
elem
- the Document Element.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |