aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim.RegionServer/OpenSimMain.cs
diff options
context:
space:
mode:
authorMW2007-03-28 18:10:52 +0000
committerMW2007-03-28 18:10:52 +0000
commit35fa85069e792579ebd44a974053d6dce288ea0a (patch)
tree8a5629c4f5e0a51e20a05123c4b1b9ea9f49f61e /OpenSim.RegionServer/OpenSimMain.cs
parent* log file name conflict (diff)
downloadopensim-SC_OLD-35fa85069e792579ebd44a974053d6dce288ea0a.zip
opensim-SC_OLD-35fa85069e792579ebd44a974053d6dce288ea0a.tar.gz
opensim-SC_OLD-35fa85069e792579ebd44a974053d6dce288ea0a.tar.bz2
opensim-SC_OLD-35fa85069e792579ebd44a974053d6dce288ea0a.tar.xz
After hours of searching for a bug, it works - User accounts in sandbox mode, currently they are not persistent between restarts (ie restarting opensim.exe) but should be persistent between sessions (login/ logout).
Use the -account command line arg to enable them and then create new accounts through the web interface
Diffstat (limited to 'OpenSim.RegionServer/OpenSimMain.cs')
-rw-r--r--OpenSim.RegionServer/OpenSimMain.cs22
1 files changed, 19 insertions, 3 deletions
diff --git a/OpenSim.RegionServer/OpenSimMain.cs b/OpenSim.RegionServer/OpenSimMain.cs
index ed3e732..07a2d6d 100644
--- a/OpenSim.RegionServer/OpenSimMain.cs
+++ b/OpenSim.RegionServer/OpenSimMain.cs
@@ -75,6 +75,7 @@ namespace OpenSim
75 public string m_physicsEngine; 75 public string m_physicsEngine;
76 public bool m_sandbox = false; 76 public bool m_sandbox = false;
77 public bool m_loginserver; 77 public bool m_loginserver;
78 public bool user_accounts = false;
78 79
79 protected ConsoleBase m_console; 80 protected ConsoleBase m_console;
80 81
@@ -145,12 +146,22 @@ namespace OpenSim
145 146
146 m_console.WriteLine("Main.cs:Startup() - Starting CAPS HTTP server"); 147 m_console.WriteLine("Main.cs:Startup() - Starting CAPS HTTP server");
147 HttpServer = new SimCAPSHTTPServer(GridServers.GridServer, Cfg.IPListenPort); 148 HttpServer = new SimCAPSHTTPServer(GridServers.GridServer, Cfg.IPListenPort);
148 HttpServer.AddRestHandler("Admin", new AdminWebFront("Admin", LocalWorld));
149 149
150 if ( m_loginserver && m_sandbox) 150 LoginServer loginServer = null;
151 if (m_loginserver && m_sandbox)
151 { 152 {
152 LoginServer loginServer = new LoginServer(GridServers.GridServer, Cfg.IPListenAddr, Cfg.IPListenPort); 153 loginServer = new LoginServer(GridServers.GridServer, Cfg.IPListenAddr, Cfg.IPListenPort, this.user_accounts);
153 loginServer.Startup(); 154 loginServer.Startup();
155
156 }
157 if((m_loginserver) && (m_sandbox) && (user_accounts))
158 {
159 this.GridServers.UserServer = loginServer;
160 HttpServer.AddRestHandler("Admin", new AdminWebFront("Admin", LocalWorld, loginServer));
161 }
162 else
163 {
164 HttpServer.AddRestHandler("Admin", new AdminWebFront("Admin", LocalWorld, null));
154 } 165 }
155 166
156 MainServerListener(); 167 MainServerListener();
@@ -210,6 +221,11 @@ namespace OpenSim
210 UseCircuitCodePacket useCircuit = (UseCircuitCodePacket)packet; 221 UseCircuitCodePacket useCircuit = (UseCircuitCodePacket)packet;
211 this.clientCircuits.Add(epSender, useCircuit.CircuitCode.Code); 222 this.clientCircuits.Add(epSender, useCircuit.CircuitCode.Code);
212 SimClient newuser = new SimClient(epSender, useCircuit, LocalWorld, ClientThreads, AssetCache, GridServers.GridServer, this, InventoryCache, m_sandbox); 223 SimClient newuser = new SimClient(epSender, useCircuit, LocalWorld, ClientThreads, AssetCache, GridServers.GridServer, this, InventoryCache, m_sandbox);
224 if ((this.GridServers.UserServer != null) && (user_accounts))
225 {
226 Console.WriteLine("setting userserver");
227 newuser.UserServer = this.GridServers.UserServer;
228 }
213 //OpenSimRoot.Instance.ClientThreads.Add(epSender, newuser); 229 //OpenSimRoot.Instance.ClientThreads.Add(epSender, newuser);
214 ClientThreads.Add(useCircuit.CircuitCode.Code, newuser); 230 ClientThreads.Add(useCircuit.CircuitCode.Code, newuser);
215 } 231 }