1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.acegisecurity.providers.rcp;
17
18 import org.acegisecurity.GrantedAuthority;
19
20
21 /***
22 * Allows remote clients to attempt authentication.
23 *
24 * @author Ben Alex
25 * @version $Id: RemoteAuthenticationManager.java,v 1.2 2005/11/17 00:55:51 benalex Exp $
26 */
27 public interface RemoteAuthenticationManager {
28
29
30 /***
31 * Attempts to authenticate the remote client using the presented username
32 * and password. If authentication is successful, an array of
33 * <code>GrantedAuthority[]</code> objects will be returned.
34 *
35 * <P>
36 * In order to maximise remoting protocol compatibility, a design decision
37 * was taken to operate with minimal arguments and return only the minimal
38 * amount information required for remote clients to enable/disable
39 * relevant user interface commands etc. There is nothing preventing users
40 * from implementing their own equivalent package that works with more
41 * complex object types.
42 * </p>
43 *
44 * @param username the username the remote client wishes to authenticate
45 * with
46 * @param password the password the remote client wishes to authenticate
47 * wish
48 *
49 * @return all of the granted authorities the specified username and
50 * password have access to
51 *
52 * @throws RemoteAuthenticationException if the authentication failed
53 */
54 public GrantedAuthority[] attemptAuthentication(String username,
55 String password) throws RemoteAuthenticationException;
56 }