001/* 002 * The contents of this file are subject to the terms of the Common Development and 003 * Distribution License (the License). You may not use this file except in compliance with the 004 * License. 005 * 006 * You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the 007 * specific language governing permission and limitations under the License. 008 * 009 * When distributing Covered Software, include this CDDL Header Notice in each file and include 010 * the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL 011 * Header, with the fields enclosed by brackets [] replaced by your own identifying 012 * information: "Portions Copyright [year] [name of copyright owner]". 013 * 014 * Copyright 2008 Sun Microsystems, Inc. 015 */ 016package org.forgerock.opendj.server.config.server; 017 018 019 020import java.util.SortedSet; 021import org.forgerock.opendj.config.server.ConfigurationChangeListener; 022import org.forgerock.opendj.ldap.DN; 023import org.forgerock.opendj.ldap.schema.AttributeType; 024 025 026 027/** 028 * A server-side interface for querying Exact Match Identity Mapper 029 * settings. 030 * <p> 031 * The Exact Match Identity Mapper maps an identifier string to user 032 * entries by searching for the entry containing a specified attribute 033 * whose value is the provided identifier. For example, the username 034 * provided by the client for DIGEST-MD5 authentication must match the 035 * value of the uid attribute 036 */ 037public interface ExactMatchIdentityMapperCfg extends IdentityMapperCfg { 038 039 /** 040 * Gets the configuration class associated with this Exact Match Identity Mapper. 041 * 042 * @return Returns the configuration class associated with this Exact Match Identity Mapper. 043 */ 044 Class<? extends ExactMatchIdentityMapperCfg> configurationClass(); 045 046 047 048 /** 049 * Register to be notified when this Exact Match Identity Mapper is changed. 050 * 051 * @param listener 052 * The Exact Match Identity Mapper configuration change listener. 053 */ 054 void addExactMatchChangeListener(ConfigurationChangeListener<ExactMatchIdentityMapperCfg> listener); 055 056 057 058 /** 059 * Deregister an existing Exact Match Identity Mapper configuration change listener. 060 * 061 * @param listener 062 * The Exact Match Identity Mapper configuration change listener. 063 */ 064 void removeExactMatchChangeListener(ConfigurationChangeListener<ExactMatchIdentityMapperCfg> listener); 065 066 067 068 /** 069 * Gets the "java-class" property. 070 * <p> 071 * Specifies the fully-qualified name of the Java class that 072 * provides the Exact Match Identity Mapper implementation. 073 * 074 * @return Returns the value of the "java-class" property. 075 */ 076 String getJavaClass(); 077 078 079 080 /** 081 * Gets the "match-attribute" property. 082 * <p> 083 * Specifies the attribute whose value should exactly match the ID 084 * string provided to this identity mapper. 085 * <p> 086 * At least one value must be provided. All values must refer to the 087 * name or OID of an attribute type defined in the directory server 088 * schema. If multiple attributes or OIDs are provided, at least one 089 * of those attributes must contain the provided ID string value in 090 * exactly one entry. The internal search performed includes a 091 * logical OR across all of these values. 092 * 093 * @return Returns an unmodifiable set containing the values of the "match-attribute" property. 094 */ 095 SortedSet<AttributeType> getMatchAttribute(); 096 097 098 099 /** 100 * Gets the "match-base-dn" property. 101 * <p> 102 * Specifies the set of base DNs below which to search for users. 103 * <p> 104 * The base DNs will be used when performing searches to map the 105 * provided ID string to a user entry. If multiple values are given, 106 * searches are performed below all specified base DNs. 107 * 108 * @return Returns an unmodifiable set containing the values of the "match-base-dn" property. 109 */ 110 SortedSet<DN> getMatchBaseDN(); 111 112}