|
PicketLink Federation Core 2.1.6.Final-redhat-2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.picketlink.identity.federation.api.saml.v2.response.SAML2Response
public class SAML2Response
API for dealing with SAML2 Response objects
Constructor Summary | |
---|---|
SAML2Response()
|
Method Summary | |
---|---|
Document |
convert(EncryptedElementType encryptedElementType)
Convert an EncryptedElement into a Document |
Document |
convert(StatusResponseType responseType)
Convert a SAML2 Response into a Document |
AssertionType |
createAssertion(String id,
NameIDType issuer)
Create an assertion |
AuthnStatementType |
createAuthnStatement(String authnContextDeclRef,
XMLGregorianCalendar issueInstant)
Create an AuthnStatement |
AuthzDecisionStatementType |
createAuthzDecisionStatementType(String resource,
DecisionType decision,
EvidenceType evidence,
ActionType... actions)
Create an Authorization Decision Statement Type |
ResponseType |
createResponseType(String ID)
Create an empty response type |
ResponseType |
createResponseType(String ID,
IssuerInfoHolder issuerInfo,
AssertionType assertion)
Create a ResponseType |
ResponseType |
createResponseType(String ID,
IssuerInfoHolder issuerInfo,
Element encryptedAssertion)
Create a ResponseType |
ResponseType |
createResponseType(String ID,
SPInfoHolder sp,
IDPInfoHolder idp,
IssuerInfoHolder issuerInfo)
Create a ResponseType NOTE:: The PicketLink STS is used to issue/update the assertion If you want to control over the assertion being issued, then use createResponseType(String, SPInfoHolder, IDPInfoHolder, IssuerInfoHolder, AssertionType) |
ResponseType |
createResponseType(String ID,
SPInfoHolder sp,
IDPInfoHolder idp,
IssuerInfoHolder issuerInfo,
AssertionType assertion)
Construct a ResponseType without calling PicketLink STS for the assertion. |
void |
createTimedConditions(AssertionType assertion,
long durationInMilis)
Add validity conditions to the SAML2 Assertion |
AssertionType |
getAssertionType(InputStream is)
Read an assertion from an input stream |
EncryptedAssertionType |
getEncryptedAssertion(InputStream is)
Get an encrypted assertion from the stream |
ResponseType |
getResponseType(InputStream is)
Read a ResponseType from an input stream |
SAML2Object |
getSAML2ObjectFromStream(InputStream is)
Read a SAML2Object from an input stream |
SAMLDocumentHolder |
getSamlDocumentHolder()
Get the parsed SAMLDocumentHolder |
void |
marshall(ResponseType responseType,
OutputStream os)
Marshall the response type to the output stream |
void |
marshall(ResponseType responseType,
Writer writer)
Marshall the ResponseType into a writer |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SAML2Response()
Method Detail |
---|
public AssertionType createAssertion(String id, NameIDType issuer)
id
- issuer
-
public AuthnStatementType createAuthnStatement(String authnContextDeclRef, XMLGregorianCalendar issueInstant)
authnContextDeclRef
- such as JBossSAMLURIConstants.AC_PASSWORD_PROTECTED_TRANSPORTissueInstant
-
public AuthzDecisionStatementType createAuthzDecisionStatementType(String resource, DecisionType decision, EvidenceType evidence, ActionType... actions)
resource
- decision
- evidence
- actions
-
public ResponseType createResponseType(String ID, SPInfoHolder sp, IDPInfoHolder idp, IssuerInfoHolder issuerInfo, AssertionType assertion) throws ConfigurationException, ProcessingException
ResponseType
without calling PicketLink STS for the assertion. The AssertionType
is generated
within this method
ID
- id of the ResponseType
sp
- idp
- issuerInfo
-
ConfigurationException
ProcessingException
public ResponseType createResponseType(String ID, SPInfoHolder sp, IDPInfoHolder idp, IssuerInfoHolder issuerInfo) throws ConfigurationException, ProcessingException
createResponseType(String, SPInfoHolder, IDPInfoHolder, IssuerInfoHolder, AssertionType)
ID
- id of the responsesp
- holder with the information about the Service Provideridp
- holder with the information on the Identity ProviderissuerInfo
- holder with information on the issuer
ConfigurationException
ProcessingException
public ResponseType createResponseType(String ID)
public ResponseType createResponseType(String ID, IssuerInfoHolder issuerInfo, AssertionType assertion) throws ConfigurationException
ID
- issuerInfo
- assertion
-
ConfigurationException
public ResponseType createResponseType(String ID, IssuerInfoHolder issuerInfo, Element encryptedAssertion) throws ConfigurationException
ID
- issuerInfo
- encryptedAssertion
- a DOM Element
that represents an encrypted assertion
ConfigurationException
public void createTimedConditions(AssertionType assertion, long durationInMilis) throws ConfigurationException, IssueInstantMissingException
assertion
- durationInMilis
-
ConfigurationException
IssueInstantMissingException
public EncryptedAssertionType getEncryptedAssertion(InputStream is) throws ParsingException, ConfigurationException, ProcessingException
is
-
ParsingException
ProcessingException
ConfigurationException
public AssertionType getAssertionType(InputStream is) throws ParsingException, ConfigurationException, ProcessingException
is
-
ParsingException
ProcessingException
ConfigurationException
public SAMLDocumentHolder getSamlDocumentHolder()
SAMLDocumentHolder
public ResponseType getResponseType(InputStream is) throws ParsingException, ConfigurationException, ProcessingException
is
-
ParsingException
ConfigurationException
ProcessingException
public SAML2Object getSAML2ObjectFromStream(InputStream is) throws ParsingException, ConfigurationException, ProcessingException
SAML2Object
from an input stream
is
-
ParsingException
ConfigurationException
ProcessingException
public Document convert(EncryptedElementType encryptedElementType) throws ConfigurationException
encryptedElementType
-
ConfigurationException
public Document convert(StatusResponseType responseType) throws ProcessingException, ConfigurationException, ParsingException
responseType
-
ParsingException
ConfigurationException
ParserConfigurationException
ProcessingException
public void marshall(ResponseType responseType, OutputStream os) throws ProcessingException
responseType
- os
-
ProcessingException
public void marshall(ResponseType responseType, Writer writer) throws ProcessingException
responseType
- writer
-
ProcessingException
|
PicketLink Federation Core 2.1.6.Final-redhat-2 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |