diff options
author | MW | 2007-05-16 17:35:27 +0000 |
---|---|---|
committer | MW | 2007-05-16 17:35:27 +0000 |
commit | 1e9a0220e69a62dd45b53753537fb4563e50412c (patch) | |
tree | bfe79152761b164dbd437b60dc025aa1f0c8c3fc /OpenSim.RegionServer/AuthenticateSessionsRemote.cs | |
parent | * removed unused new-login.dat (diff) | |
download | opensim-SC-1e9a0220e69a62dd45b53753537fb4563e50412c.zip opensim-SC-1e9a0220e69a62dd45b53753537fb4563e50412c.tar.gz opensim-SC-1e9a0220e69a62dd45b53753537fb4563e50412c.tar.bz2 opensim-SC-1e9a0220e69a62dd45b53753537fb4563e50412c.tar.xz |
Quite big change to how Sessions/circuits are Authenticated. Seems to work okay but needs a lot more testing.
Diffstat (limited to 'OpenSim.RegionServer/AuthenticateSessionsRemote.cs')
-rw-r--r-- | OpenSim.RegionServer/AuthenticateSessionsRemote.cs | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/OpenSim.RegionServer/AuthenticateSessionsRemote.cs b/OpenSim.RegionServer/AuthenticateSessionsRemote.cs new file mode 100644 index 0000000..57c98e4 --- /dev/null +++ b/OpenSim.RegionServer/AuthenticateSessionsRemote.cs | |||
@@ -0,0 +1,44 @@ | |||
1 | using System; | ||
2 | using System.Collections; | ||
3 | using System.Collections.Generic; | ||
4 | using System.Text; | ||
5 | using System.Xml; | ||
6 | using libsecondlife; | ||
7 | using OpenSim.Framework.Types; | ||
8 | using Nwc.XmlRpc; | ||
9 | |||
10 | namespace OpenSim | ||
11 | { | ||
12 | public class AuthenticateSessionsRemote : AuthenticateSessionsBase | ||
13 | { | ||
14 | public AuthenticateSessionsRemote() | ||
15 | { | ||
16 | |||
17 | } | ||
18 | |||
19 | public XmlRpcResponse ExpectUser(XmlRpcRequest request) | ||
20 | { | ||
21 | Hashtable requestData = (Hashtable)request.Params[0]; | ||
22 | AgentCircuitData agentData = new AgentCircuitData(); | ||
23 | agentData.SessionID = new LLUUID((string)requestData["session_id"]); | ||
24 | agentData.SecureSessionID = new LLUUID((string)requestData["secure_session_id"]); | ||
25 | agentData.firstname = (string)requestData["firstname"]; | ||
26 | agentData.lastname = (string)requestData["lastname"]; | ||
27 | agentData.AgentID = new LLUUID((string)requestData["agent_id"]); | ||
28 | agentData.circuitcode = Convert.ToUInt32(requestData["circuit_code"]); | ||
29 | if (requestData.ContainsKey("child_agent") && requestData["child_agent"].Equals("1")) | ||
30 | { | ||
31 | agentData.child = true; | ||
32 | } | ||
33 | else | ||
34 | { | ||
35 | agentData.startpos = new LLVector3(Convert.ToUInt32(requestData["startpos_x"]), Convert.ToUInt32(requestData["startpos_y"]), Convert.ToUInt32(requestData["startpos_z"])); | ||
36 | agentData.child = false; | ||
37 | } | ||
38 | |||
39 | this.AddNewCircuit(agentData.circuitcode, agentData); | ||
40 | |||
41 | return new XmlRpcResponse(); | ||
42 | } | ||
43 | } | ||
44 | } | ||