mirror of
https://github.com/opensim/opensim.git
synced 2026-08-08 18:25:33 +08:00
More refactoring.
Changed AuthenticateSession handling, now calls a method in UDPServer. (but is likely to change again soon)
This commit is contained in:
@@ -24,6 +24,8 @@ using OpenSim.GenericConfig;
|
||||
|
||||
namespace OpenSim
|
||||
{
|
||||
public delegate AuthenticateResponse AuthenticateSessionHandler(LLUUID sessionID, LLUUID agentID, uint circuitCode);
|
||||
|
||||
public class UDPServer : OpenSimNetworkHandler
|
||||
{
|
||||
private Dictionary<EndPoint, uint> clientCircuits = new Dictionary<EndPoint, uint>();
|
||||
@@ -45,6 +47,7 @@ namespace OpenSim
|
||||
private bool m_sandbox = false;
|
||||
private bool user_accounts = false;
|
||||
private ConsoleBase m_console;
|
||||
public AuthenticateSessionHandler AuthenticateHandler;
|
||||
|
||||
public PacketServer PacketServer
|
||||
{
|
||||
@@ -78,6 +81,7 @@ namespace OpenSim
|
||||
this.user_accounts = accounts;
|
||||
this.m_console = console;
|
||||
PacketServer packetServer = new PacketServer(this);
|
||||
this.AuthenticateHandler = new AuthenticateSessionHandler(this.m_gridServers.GridServer.AuthenticateSession);
|
||||
}
|
||||
|
||||
protected virtual void OnReceivedData(IAsyncResult result)
|
||||
@@ -178,5 +182,10 @@ namespace OpenSim
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public virtual AuthenticateResponse AuthenticateSession(LLUUID sessionID, LLUUID agentID, uint circuitCode)
|
||||
{
|
||||
return this.AuthenticateHandler(sessionID, agentID, circuitCode);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user