01: /* Copyright 2004, 2005, 2006 Acegi Technology Pty Limited
02: *
03: * Licensed under the Apache License, Version 2.0 (the "License");
04: * you may not use this file except in compliance with the License.
05: * You may obtain a copy of the License at
06: *
07: * http://www.apache.org/licenses/LICENSE-2.0
08: *
09: * Unless required by applicable law or agreed to in writing, software
10: * distributed under the License is distributed on an "AS IS" BASIS,
11: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12: * See the License for the specific language governing permissions and
13: * limitations under the License.
14: */
15:
16: package org.acegisecurity.userdetails.ldap;
17:
18: import org.acegisecurity.userdetails.UserDetails;
19:
20: import javax.naming.directory.Attributes;
21: import javax.naming.ldap.Control;
22:
23: /**
24: * Captures the information for a user's LDAP entry.
25: *
26: * @author Luke Taylor
27: * @version $Id$
28: */
29: public interface LdapUserDetails extends UserDetails {
30: //~ Methods ========================================================================================================
31:
32: /**
33: * The attributes for the user's entry in the directory (or a subset of them, depending on what was
34: * retrieved from the directory)
35: *
36: * @return the user's attributes, or an empty array if none were obtained, never null.
37: */
38: Attributes getAttributes();
39:
40: /**
41: * Returns any LDAP response controls (as part of a user authentication process, for example).
42: *
43: * @return an array of LDAP Control instances, never null
44: */
45: Control[] getControls();
46:
47: /**
48: * The DN of the entry for this user's account.
49: *
50: * @return the user's DN
51: */
52: String getDn();
53: }
|