Package com.sun.identity.saml.plugins
Class DefaultAttributeMapper
- java.lang.Object
-
- com.sun.identity.saml.plugins.DefaultAttributeMapper
-
- All Implemented Interfaces:
AttributeMapper
public class DefaultAttributeMapper extends Object implements AttributeMapper
The classDefaultAttributeMapperprovide a default implementation of theAttributeMapperinterface.
-
-
Constructor Summary
Constructors Constructor Description DefaultAttributeMapper()Default Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ListgetAttributes(AttributeQuery query, String sourceID, Object token)This method first mapps the Subject in the query to a local site account using the AccountMapper defined in the SAML Service.AssertiongetSSOAssertion(AttributeQuery query)This method exams the SubjectConfirmationData of the Subject in the AttributeQuery.StringgetSSOTokenID(AttributeQuery query)This method exams the SubjectConfirmation of the Subject in the AttributeQuery.
-
-
-
Method Detail
-
getSSOTokenID
public String getSSOTokenID(AttributeQuery query)
This method exams the SubjectConfirmation of the Subject in the AttributeQuery. If it has only one ConfirmationMethod, and this ConfirmationMethod equals to "urn:com:sun:identity"; and its SubjectConfirmationData contains TEXT node only, then the method returns the concatenated string of all the TEXT nodes. Otherwise, it returns null.- Specified by:
getSSOTokenIDin interfaceAttributeMapper- Parameters:
query- theAttributeQueryobject.- Returns:
- String which is the single sign on token ID.
- See Also:
AttributeMapper.getSSOTokenID(com.sun.identity.saml.protocol.AttributeQuery)
-
getSSOAssertion
public Assertion getSSOAssertion(AttributeQuery query)
This method exams the SubjectConfirmationData of the Subject in the AttributeQuery. It returns the first Assertion that contains at least one AuthenticationStatement.- Specified by:
getSSOAssertionin interfaceAttributeMapper- Parameters:
query- The receivedAttributeQuery.- Returns:
- Assertion The assertion contained inside the query.
- See Also:
AttributeMapper.getSSOAssertion(com.sun.identity.saml.protocol.AttributeQuery)
-
getAttributes
public List getAttributes(AttributeQuery query, String sourceID, Object token) throws SAMLException
This method first mapps the Subject in the query to a local site account using the AccountMapper defined in the SAML Service. The source ID is used to find the appropriate AccountMapper. It then calls the User Management API to obtain the attribute value using the Session and the attribute name in the AttributeDesignator(s) of the query. If there is no AttributeDesignator in the query, attributes of services specified as userServiceNameList in amSAML.properties will be returned.- Specified by:
getAttributesin interfaceAttributeMapper- Parameters:
query- theAttributeQueryobject.sourceID- the Source Identifier.token- User Session- Returns:
- A List of Attributes
- Throws:
SAMLException- if there is an error.
-
-