diff options
Diffstat (limited to 'OpenSim/Services/Interfaces/IAuthenticationService.cs')
-rw-r--r-- | OpenSim/Services/Interfaces/IAuthenticationService.cs | 30 |
1 files changed, 19 insertions, 11 deletions
diff --git a/OpenSim/Services/Interfaces/IAuthenticationService.cs b/OpenSim/Services/Interfaces/IAuthenticationService.cs index 35831c1..fa45cbc 100644 --- a/OpenSim/Services/Interfaces/IAuthenticationService.cs +++ b/OpenSim/Services/Interfaces/IAuthenticationService.cs | |||
@@ -30,31 +30,39 @@ using OpenMetaverse; | |||
30 | 30 | ||
31 | namespace OpenSim.Services.Interfaces | 31 | namespace OpenSim.Services.Interfaces |
32 | { | 32 | { |
33 | // Generic Authentication service used for identifying | ||
34 | // and authenticating principals. | ||
35 | // Principals may be clients acting on users' behalf, | ||
36 | // or any other components that need | ||
37 | // verifiable identification. | ||
38 | // | ||
33 | public interface IAuthenticationService | 39 | public interface IAuthenticationService |
34 | { | 40 | { |
35 | // Create a new user session. If one exists, it is cleared | 41 | // Check the pricipal's password |
36 | // | 42 | // |
37 | UUID AllocateUserSession(UUID userID); | 43 | bool Authenticate(UUID principalID, string password); |
38 | 44 | ||
39 | // Get a user key from an authentication token. This must be | 45 | // Get a service key given that principal's |
40 | // done before the session allocated above is considered valid. | 46 | // authentication token (master key). |
41 | // Repeated calls to this method with the same auth token will | ||
42 | // create different keys and invalidate the previous ne. | ||
43 | // | 47 | // |
44 | string GetUserKey(UUID userID, string authToken); | 48 | string GetKey(UUID principalID, string authToken); |
45 | 49 | ||
46 | // Verify that a user key is valid | 50 | // Verify that a principal key is valid |
47 | // | 51 | // |
48 | bool VerifyUserKey(UUID userID, string key); | 52 | bool VerifyKey(UUID principalID, string key); |
53 | |||
54 | // Create a new user session. If one exists, it is cleared | ||
55 | // | ||
56 | UUID AllocateUserSession(UUID userID); | ||
49 | 57 | ||
50 | // Verify that a user session ID is valid. A session ID is | 58 | // Verify that a user session ID is valid. A session ID is |
51 | // considered valid when a user has successfully authenticated | 59 | // considered valid when a user has successfully authenticated |
52 | // at least one time inside that session. | 60 | // at least one time inside that session. |
53 | // | 61 | // |
54 | bool VerifyUserSession(UUID userID, UUID session); | 62 | bool VerifyUserSession(UUID principalID, UUID session); |
55 | 63 | ||
56 | // Remove a user session identifier and deauthenticate the user | 64 | // Remove a user session identifier and deauthenticate the user |
57 | // | 65 | // |
58 | void DestroyUserSession(UUID userID); | 66 | void DestroyUserSession(UUID principalID); |
59 | } | 67 | } |
60 | } | 68 | } |