Class AttributeMapping
- java.lang.Object
- 
- org.wildfly.security.auth.realm.ldap.AttributeMapping
 
- 
 public class AttributeMapping extends Object Definition of a mapping from LDAP to an Elytron attribute.- Author:
- Darran Lofthouse
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classAttributeMapping.Builder
 - 
Field SummaryFields Modifier and Type Field Description static StringDEFAULT_DN_NAMEstatic StringDEFAULT_FILTERED_NAMEstatic StringDEFAULT_ROLE_RECURSION_ATTRIBUTEprivate Stringfilterprivate StringldapNameprivate Stringnameprivate Stringrdnprivate booleanrecursiveSearchprivate Stringreferenceprivate introleRecursionDepthprivate StringroleRecursionNameprivate StringsearchDn
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AttributeMapping.BuilderfromFilter(String filter)Create an attribute mapping based on the results of the givenfilter.static AttributeMapping.BuilderfromIdentity()Create an attribute mapping using LDAP entry of identity itself.static AttributeMapping.BuilderfromReference(String reference)Create an attribute mapping using LDAP entry referenced by attribute of identity entry.(package private) StringgetFilter()(package private) StringgetIdentityLdapName()Get name of LDAP attribute to obtain from identity entry(package private) StringgetLdapName()(package private) StringgetName()(package private) StringgetRdn()(package private) booleangetRecursiveSearch()(package private) StringgetReference()(package private) intgetRoleRecursionDepth()(package private) StringgetRoleRecursionName()(package private) StringgetSearchDn()(package private) booleanisFilteredOrReference()(package private) booleansearchInIdentityContext()Determine which context should be used to search filtered/referenced entry.
 
- 
- 
- 
Field Detail- 
DEFAULT_FILTERED_NAMEpublic static final String DEFAULT_FILTERED_NAME - See Also:
- Constant Field Values
 
 - 
DEFAULT_DN_NAMEpublic static final String DEFAULT_DN_NAME - See Also:
- Constant Field Values
 
 - 
DEFAULT_ROLE_RECURSION_ATTRIBUTEpublic static final String DEFAULT_ROLE_RECURSION_ATTRIBUTE - See Also:
- Constant Field Values
 
 - 
ldapNameprivate final String ldapName 
 - 
searchDnprivate final String searchDn 
 - 
recursiveSearchprivate final boolean recursiveSearch 
 - 
filterprivate final String filter 
 - 
referenceprivate final String reference 
 - 
nameprivate final String name 
 - 
rdnprivate final String rdn 
 - 
roleRecursionDepthprivate final int roleRecursionDepth 
 - 
roleRecursionNameprivate final String roleRecursionName 
 
- 
 - 
Method Detail- 
getLdapNameString getLdapName() 
 - 
getIdentityLdapNameString getIdentityLdapName() Get name of LDAP attribute to obtain from identity entry- Returns:
- LDAP attribute to obtain from identity entry
 
 - 
getNameString getName() 
 - 
getSearchDnString getSearchDn() 
 - 
getRecursiveSearchboolean getRecursiveSearch() 
 - 
getFilterString getFilter() 
 - 
getRdnString getRdn() 
 - 
getReferenceString getReference() 
 - 
getRoleRecursionDepthint getRoleRecursionDepth() 
 - 
getRoleRecursionNameString getRoleRecursionName() 
 - 
isFilteredOrReferenceboolean isFilteredOrReference() 
 - 
searchInIdentityContextboolean searchInIdentityContext() Determine which context should be used to search filtered/referenced entry. Has effect if the identity is behind referral, in different context. Iftrue, attribute will be searched in context, where was the identity found.DirContextof the LdapRealm will be used otherwise.
 - 
fromIdentitypublic static AttributeMapping.Builder fromIdentity() Create an attribute mapping using LDAP entry of identity itself. - Returns:
- this builder
 
 - 
fromFilterpublic static AttributeMapping.Builder fromFilter(String filter) Create an attribute mapping based on the results of the given filter.The filtermay have one and exactly one {0} string that will be used to replace with the distinguished name of the identity. In this case, the filter is specially useful when the values for this attribute should be obtained from a separated entry. For instance, retrieving roles from entries with a object class of groupOfNames where the identity's DN is a value of a member attribute.- Parameters:
- filter- the filter that is going to be used to search for entries and obtain values for this attribute
- Returns:
- this builder
 
 - 
fromReferencepublic static AttributeMapping.Builder fromReference(String reference) Create an attribute mapping using LDAP entry referenced by attribute of identity entry. - Parameters:
- reference- the name of LDAP attribute containing DN of LDAP entry, from which should be value loaded.
- Returns:
- this builder
 
 
- 
 
-