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