More authentication stuff
parent
e2499fbbc1
commit
e6b3c83b7d
|
@ -3,6 +3,7 @@ using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using Nwc.XmlRpc;
|
using Nwc.XmlRpc;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
|
using libsecondlife;
|
||||||
|
|
||||||
namespace OpenGrid.Framework.Manager {
|
namespace OpenGrid.Framework.Manager {
|
||||||
|
|
||||||
|
@ -19,8 +20,18 @@ namespace OpenGrid.Framework.Manager {
|
||||||
Hashtable requestData = (Hashtable)request.Params[0];
|
Hashtable requestData = (Hashtable)request.Params[0];
|
||||||
Hashtable responseData = new Hashtable();
|
Hashtable responseData = new Hashtable();
|
||||||
|
|
||||||
|
if(requestData.ContainsKey("session_id")) {
|
||||||
|
if(GridManagementAgent.SessionExists(new LLUUID((string)requestData["session_id"]))) {
|
||||||
responseData["msg"]="Shutdown command accepted";
|
responseData["msg"]="Shutdown command accepted";
|
||||||
(new Thread(new ThreadStart(ZOMGServerIsNowTerminallyIll))).Start();
|
(new Thread(new ThreadStart(ZOMGServerIsNowTerminallyIll))).Start();
|
||||||
|
} else {
|
||||||
|
response.IsFault=true;
|
||||||
|
responseData["error"]="bad session ID";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
response.IsFault=true;
|
||||||
|
responseData["error"]="no session ID";
|
||||||
|
}
|
||||||
|
|
||||||
response.Value = responseData;
|
response.Value = responseData;
|
||||||
return response;
|
return response;
|
||||||
|
|
Loading…
Reference in New Issue