aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/Interfaces/IAuthenticationService.cs
diff options
context:
space:
mode:
authorMelanie Thielker2009-06-30 21:48:03 +0000
committerMelanie Thielker2009-06-30 21:48:03 +0000
commit858b0a2efd4790042c3e248ce895a426462a2576 (patch)
tree2d9e9f61b5ca0219537e6debbcf75c703be52854 /OpenSim/Services/Interfaces/IAuthenticationService.cs
parentFrom: Chris Yeoh <yeohc@au1.ibm.com> (diff)
downloadopensim-SC_OLD-858b0a2efd4790042c3e248ce895a426462a2576.zip
opensim-SC_OLD-858b0a2efd4790042c3e248ce895a426462a2576.tar.gz
opensim-SC_OLD-858b0a2efd4790042c3e248ce895a426462a2576.tar.bz2
opensim-SC_OLD-858b0a2efd4790042c3e248ce895a426462a2576.tar.xz
Updated services to allow external applications like web interfaces to
authenticate against the services. This paves the way for such apps to directly talk to services.
Diffstat (limited to 'OpenSim/Services/Interfaces/IAuthenticationService.cs')
-rw-r--r--OpenSim/Services/Interfaces/IAuthenticationService.cs42
1 files changed, 34 insertions, 8 deletions
diff --git a/OpenSim/Services/Interfaces/IAuthenticationService.cs b/OpenSim/Services/Interfaces/IAuthenticationService.cs
index fa45cbc..2402414 100644
--- a/OpenSim/Services/Interfaces/IAuthenticationService.cs
+++ b/OpenSim/Services/Interfaces/IAuthenticationService.cs
@@ -38,9 +38,9 @@ namespace OpenSim.Services.Interfaces
38 // 38 //
39 public interface IAuthenticationService 39 public interface IAuthenticationService
40 { 40 {
41 // Check the pricipal's password 41 //////////////////////////////////////////////////
42 // Web login key portion
42 // 43 //
43 bool Authenticate(UUID principalID, string password);
44 44
45 // Get a service key given that principal's 45 // Get a service key given that principal's
46 // authentication token (master key). 46 // authentication token (master key).
@@ -51,18 +51,44 @@ namespace OpenSim.Services.Interfaces
51 // 51 //
52 bool VerifyKey(UUID principalID, string key); 52 bool VerifyKey(UUID principalID, string key);
53 53
54 // Create a new user session. If one exists, it is cleared 54 //////////////////////////////////////////////////
55 // 55 // Password auth portion
56 UUID AllocateUserSession(UUID userID); 56 //
57
58 // Here's how thos works, and why.
59 //
60 // The authentication methods will return the existing session,
61 // or UUID.Zero if authentication failed. If there is no session,
62 // they will create one.
63 // The CreateUserSession method will unconditionally create a session
64 // and invalidate the prior session.
65 // Grid login uses this method to make sure that the session is
66 // fresh and new. Other software, like management applications,
67 // can obtain this existing session if they have a key or password
68 // for that account, this allows external apps to obtain credentials
69 // and use authenticating interface methods.
70 //
71
72 // Check the pricipal's password
73 //
74 UUID AuthenticatePassword(UUID principalID, string password);
75
76 // Check the principal's key
77 //
78 UUID AuthenticateKey(UUID principalID, string password);
79
80 // Create a new session, invalidating the old ones
81 //
82 UUID CreateUserSession(UUID principalID, UUID oldSessionID);
57 83
58 // Verify that a user session ID is valid. A session ID is 84 // Verify that a user session ID is valid. A session ID is
59 // considered valid when a user has successfully authenticated 85 // considered valid when a user has successfully authenticated
60 // at least one time inside that session. 86 // at least one time inside that session.
61 // 87 //
62 bool VerifyUserSession(UUID principalID, UUID session); 88 bool VerifyUserSession(UUID principalID, UUID sessionID);
63 89
64 // Remove a user session identifier and deauthenticate the user 90 // Deauthenticate user
65 // 91 //
66 void DestroyUserSession(UUID principalID); 92 bool DestroyUserSession(UUID principalID, UUID sessionID);
67 } 93 }
68} 94}