| | |
| | | /** The set of attributes to return in search result entries. */ |
| | | private LinkedHashSet<String> requestedAttributes; |
| | | |
| | | |
| | | |
| | | /** |
| | | * Creates a new instance of this exact match identity mapper. All |
| | | * initialization should be performed in the {@code initializeIdentityMapper} |
| | |
| | | // Don't do any initialization here. |
| | | } |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void initializeIdentityMapper( |
| | | ExactMatchIdentityMapperCfg configuration) |
| | |
| | | currentConfig = configuration; |
| | | configEntryDN = currentConfig.dn(); |
| | | |
| | | |
| | | // Get the attribute types to use for the searches. Ensure that they are |
| | | // all indexed for equality. |
| | | attributeTypes = |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | // Create the attribute list to include in search requests. We want to |
| | | // include all user and operational attributes. |
| | | requestedAttributes = newLinkedHashSet("*", "+"); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * Performs any finalization that may be necessary for this identity mapper. |
| | | */ |
| | | @Override |
| | | public void finalizeIdentityMapper() |
| | | { |
| | | currentConfig.removeExactMatchChangeListener(this); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * Retrieves the user entry that was mapped to the provided identification |
| | | * string. |
| | |
| | | ExactMatchIdentityMapperCfg config = currentConfig; |
| | | AttributeType[] attributeTypes = this.attributeTypes; |
| | | |
| | | |
| | | // Construct the search filter to use to make the determination. |
| | | SearchFilter filter; |
| | | if (attributeTypes.length == 1) |
| | |
| | | filter = SearchFilter.createORFilter(filterComps); |
| | | } |
| | | |
| | | |
| | | // Iterate through the set of search bases and process an internal search |
| | | // to find any matching entries. Since we'll only allow a single match, |
| | | // then use size and time limits to constrain costly searches resulting from |
| | |
| | | return matchingEntry; |
| | | } |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public boolean isConfigurationAcceptable(IdentityMapperCfg configuration, |
| | | List<LocalizableMessage> unacceptableReasons) |
| | |
| | | return isConfigurationChangeAcceptable(config, unacceptableReasons); |
| | | } |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public boolean isConfigurationChangeAcceptable( |
| | | ExactMatchIdentityMapperCfg configuration, |
| | |
| | | return configAcceptable; |
| | | } |
| | | |
| | | |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public ConfigChangeResult applyConfigurationChange( |
| | | ExactMatchIdentityMapperCfg configuration) |