aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Application
diff options
context:
space:
mode:
authorMW2007-08-11 11:59:51 +0000
committerMW2007-08-11 11:59:51 +0000
commit114807b9d1caeffad1f245982baa2c07e88ee470 (patch)
treef3a3ed3c24de47085192d7215a81ef25254fceda /OpenSim/Region/Application
parentFew small fixes (diff)
downloadopensim-SC_OLD-114807b9d1caeffad1f245982baa2c07e88ee470.zip
opensim-SC_OLD-114807b9d1caeffad1f245982baa2c07e88ee470.tar.gz
opensim-SC_OLD-114807b9d1caeffad1f245982baa2c07e88ee470.tar.bz2
opensim-SC_OLD-114807b9d1caeffad1f245982baa2c07e88ee470.tar.xz
Made account Authentication optional in "sandbox/standalone" mode. Just change "standalone_authenticate = false" to be true in OpenSim.ini. Then as per grid mode, you can use the "create user" command to create new accounts.
Diffstat (limited to 'OpenSim/Region/Application')
-rw-r--r--OpenSim/Region/Application/OpenSimMain.cs22
1 files changed, 20 insertions, 2 deletions
diff --git a/OpenSim/Region/Application/OpenSimMain.cs b/OpenSim/Region/Application/OpenSimMain.cs
index 7316db4..611041d 100644
--- a/OpenSim/Region/Application/OpenSimMain.cs
+++ b/OpenSim/Region/Application/OpenSimMain.cs
@@ -53,6 +53,7 @@ using OpenSim.Framework.Utilities;
53 53
54namespace OpenSim 54namespace OpenSim
55{ 55{
56 public delegate void ConsoleCommand(string comParams);
56 57
57 public class OpenSimMain : RegionApplicationBase, conscmd_callback 58 public class OpenSimMain : RegionApplicationBase, conscmd_callback
58 { 59 {
@@ -68,7 +69,10 @@ namespace OpenSim
68 protected List<Scene> m_localScenes = new List<Scene>(); 69 protected List<Scene> m_localScenes = new List<Scene>();
69 70
70 private bool m_silent; 71 private bool m_silent;
71 private string m_logFilename = ("region-console" + ".log"); 72 private string m_logFilename = ("region-console.log");
73
74 private bool standaloneAuthenticate = false;
75 public ConsoleCommand CreateAccount = null;
72 76
73 public OpenSimMain(IConfigSource configSource) 77 public OpenSimMain(IConfigSource configSource)
74 : base() 78 : base()
@@ -98,6 +102,8 @@ namespace OpenSim
98 m_silent = configSource.Configs["Startup"].GetBoolean("noverbose", false); 102 m_silent = configSource.Configs["Startup"].GetBoolean("noverbose", false);
99 103
100 m_storageDLL = configSource.Configs["Startup"].GetString("storage_plugin", "OpenSim.DataStore.NullStorage.dll"); 104 m_storageDLL = configSource.Configs["Startup"].GetString("storage_plugin", "OpenSim.DataStore.NullStorage.dll");
105
106 standaloneAuthenticate = configSource.Configs["Startup"].GetBoolean("standalone_authenticate", false);
101 } 107 }
102 108
103 /// <summary> 109 /// <summary>
@@ -122,7 +128,12 @@ namespace OpenSim
122 128
123 if (m_sandbox) 129 if (m_sandbox)
124 { 130 {
125 m_commsManager = new CommunicationsLocal(m_networkServersInfo, m_httpServer, m_assetCache); 131 CommunicationsLocal localComms = new CommunicationsLocal(m_networkServersInfo, m_httpServer, m_assetCache, standaloneAuthenticate);
132 m_commsManager = localComms;
133 if(standaloneAuthenticate)
134 {
135 this.CreateAccount = localComms.do_create;
136 }
126 } 137 }
127 else 138 else
128 { 139 {
@@ -320,6 +331,13 @@ namespace OpenSim
320 Shutdown(); 331 Shutdown();
321 break; 332 break;
322 333
334 case "create":
335 if (CreateAccount != null)
336 {
337 CreateAccount(cmdparams[0]);
338 }
339 break;
340
323 default: 341 default:
324 m_log.Error("Unknown command"); 342 m_log.Error("Unknown command");
325 break; 343 break;