001    /*
002     * CDDL HEADER START
003     *
004     * The contents of this file are subject to the terms of the
005     * Common Development and Distribution License, Version 1.0 only
006     * (the "License").  You may not use this file except in compliance
007     * with the License.
008     *
009     * You can obtain a copy of the license at
010     * trunk/opends/resource/legal-notices/OpenDS.LICENSE
011     * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
012     * See the License for the specific language governing permissions
013     * and limitations under the License.
014     *
015     * When distributing Covered Code, include this CDDL HEADER in each
016     * file and include the License file at
017     * trunk/opends/resource/legal-notices/OpenDS.LICENSE.  If applicable,
018     * add the following below this CDDL HEADER, with the fields enclosed
019     * by brackets "[]" replaced with your own identifying information:
020     *      Portions Copyright [yyyy] [name of copyright owner]
021     *
022     * CDDL HEADER END
023     *
024     *
025     *      Copyright 2008 Sun Microsystems, Inc.
026     */
027    package org.opends.server.admin.std.client;
028    
029    
030    
031    import java.util.Collection;
032    import java.util.SortedSet;
033    import org.opends.server.admin.IllegalPropertyValueException;
034    import org.opends.server.admin.ManagedObjectDefinition;
035    import org.opends.server.admin.std.meta.FingerprintCertificateMapperCfgDefn.FingerprintAlgorithm;
036    import org.opends.server.admin.std.server.FingerprintCertificateMapperCfg;
037    import org.opends.server.types.AttributeType;
038    import org.opends.server.types.DN;
039    
040    
041    
042    /**
043     * A client-side interface for reading and modifying Fingerprint
044     * Certificate Mapper settings.
045     * <p>
046     * The Fingerprint Certificate Mapper maps client certificates to user
047     * entries by looking for the MD5 or SHA1 fingerprint in a specified
048     * attribute of user entries.
049     */
050    public interface FingerprintCertificateMapperCfgClient extends CertificateMapperCfgClient {
051    
052      /**
053       * Get the configuration definition associated with this Fingerprint Certificate Mapper.
054       *
055       * @return Returns the configuration definition associated with this Fingerprint Certificate Mapper.
056       */
057      ManagedObjectDefinition<? extends FingerprintCertificateMapperCfgClient, ? extends FingerprintCertificateMapperCfg> definition();
058    
059    
060    
061      /**
062       * Gets the "fingerprint-algorithm" property.
063       * <p>
064       * Specifies the name of the digest algorithm to compute the
065       * fingerprint of client certificates.
066       *
067       * @return Returns the value of the "fingerprint-algorithm" property.
068       */
069      FingerprintAlgorithm getFingerprintAlgorithm();
070    
071    
072    
073      /**
074       * Sets the "fingerprint-algorithm" property.
075       * <p>
076       * Specifies the name of the digest algorithm to compute the
077       * fingerprint of client certificates.
078       *
079       * @param value The value of the "fingerprint-algorithm" property.
080       * @throws IllegalPropertyValueException
081       *           If the new value is invalid.
082       */
083      void setFingerprintAlgorithm(FingerprintAlgorithm value) throws IllegalPropertyValueException;
084    
085    
086    
087      /**
088       * Gets the "fingerprint-attribute" property.
089       * <p>
090       * Specifies the attribute in which to look for the fingerprint.
091       * <p>
092       * Values of the fingerprint attribute should exactly match the MD5
093       * or SHA1 representation of the certificate fingerprint.
094       *
095       * @return Returns the value of the "fingerprint-attribute" property.
096       */
097      AttributeType getFingerprintAttribute();
098    
099    
100    
101      /**
102       * Sets the "fingerprint-attribute" property.
103       * <p>
104       * Specifies the attribute in which to look for the fingerprint.
105       * <p>
106       * Values of the fingerprint attribute should exactly match the MD5
107       * or SHA1 representation of the certificate fingerprint.
108       *
109       * @param value The value of the "fingerprint-attribute" property.
110       * @throws IllegalPropertyValueException
111       *           If the new value is invalid.
112       */
113      void setFingerprintAttribute(AttributeType value) throws IllegalPropertyValueException;
114    
115    
116    
117      /**
118       * Gets the "java-class" property.
119       * <p>
120       * Specifies the fully-qualified name of the Java class that
121       * provides the Fingerprint Certificate Mapper implementation.
122       *
123       * @return Returns the value of the "java-class" property.
124       */
125      String getJavaClass();
126    
127    
128    
129      /**
130       * Sets the "java-class" property.
131       * <p>
132       * Specifies the fully-qualified name of the Java class that
133       * provides the Fingerprint Certificate Mapper implementation.
134       *
135       * @param value The value of the "java-class" property.
136       * @throws IllegalPropertyValueException
137       *           If the new value is invalid.
138       */
139      void setJavaClass(String value) throws IllegalPropertyValueException;
140    
141    
142    
143      /**
144       * Gets the "user-base-dn" property.
145       * <p>
146       * Specifies the set of base DNs below which to search for users.
147       * <p>
148       * The base DNs are used when performing searches to map the client
149       * certificates to a user entry.
150       *
151       * @return Returns the values of the "user-base-dn" property.
152       */
153      SortedSet<DN> getUserBaseDN();
154    
155    
156    
157      /**
158       * Sets the "user-base-dn" property.
159       * <p>
160       * Specifies the set of base DNs below which to search for users.
161       * <p>
162       * The base DNs are used when performing searches to map the client
163       * certificates to a user entry.
164       *
165       * @param values The values of the "user-base-dn" property.
166       * @throws IllegalPropertyValueException
167       *           If one or more of the new values are invalid.
168       */
169      void setUserBaseDN(Collection<DN> values) throws IllegalPropertyValueException;
170    
171    }