mirror of
https://github.com/opensim/opensim.git
synced 2026-08-11 20:05:33 +08:00
Added viewer's channel, mac, and id0 to agent circuit data. Also moved client ip address to agent circuit data, so that it's always there.
This commit is contained in:
@@ -208,7 +208,8 @@ namespace OpenSim.Services.LLLoginService
|
||||
return response;
|
||||
}
|
||||
|
||||
public LoginResponse Login(string firstName, string lastName, string passwd, string startLocation, UUID scopeID, string clientVersion, IPEndPoint clientIP)
|
||||
public LoginResponse Login(string firstName, string lastName, string passwd, string startLocation, UUID scopeID,
|
||||
string clientVersion, string channel, string mac, string id0, IPEndPoint clientIP)
|
||||
{
|
||||
bool success = false;
|
||||
UUID session = UUID.Random();
|
||||
@@ -340,7 +341,8 @@ namespace OpenSim.Services.LLLoginService
|
||||
//
|
||||
string reason = string.Empty;
|
||||
GridRegion dest;
|
||||
AgentCircuitData aCircuit = LaunchAgentAtGrid(gatekeeper, destination, account, avatar, session, secureSession, position, where, clientVersion, clientIP, out where, out reason, out dest);
|
||||
AgentCircuitData aCircuit = LaunchAgentAtGrid(gatekeeper, destination, account, avatar, session, secureSession, position, where,
|
||||
clientVersion, channel, mac, id0, clientIP, out where, out reason, out dest);
|
||||
destination = dest;
|
||||
if (aCircuit == null)
|
||||
{
|
||||
@@ -600,7 +602,8 @@ namespace OpenSim.Services.LLLoginService
|
||||
}
|
||||
|
||||
protected AgentCircuitData LaunchAgentAtGrid(GridRegion gatekeeper, GridRegion destination, UserAccount account, AvatarData avatar,
|
||||
UUID session, UUID secureSession, Vector3 position, string currentWhere, string viewer, IPEndPoint clientIP, out string where, out string reason, out GridRegion dest)
|
||||
UUID session, UUID secureSession, Vector3 position, string currentWhere, string viewer, string channel, string mac, string id0,
|
||||
IPEndPoint clientIP, out string where, out string reason, out GridRegion dest)
|
||||
{
|
||||
where = currentWhere;
|
||||
ISimulationService simConnector = null;
|
||||
@@ -640,7 +643,7 @@ namespace OpenSim.Services.LLLoginService
|
||||
if (m_UserAgentService == null && simConnector != null)
|
||||
{
|
||||
circuitCode = (uint)Util.RandomClass.Next(); ;
|
||||
aCircuit = MakeAgent(destination, account, avatar, session, secureSession, circuitCode, position, viewer);
|
||||
aCircuit = MakeAgent(destination, account, avatar, session, secureSession, circuitCode, position, clientIP.Address.ToString(), viewer, channel, mac, id0);
|
||||
success = LaunchAgentDirectly(simConnector, destination, aCircuit, out reason);
|
||||
if (!success && m_GridService != null)
|
||||
{
|
||||
@@ -665,7 +668,7 @@ namespace OpenSim.Services.LLLoginService
|
||||
if (m_UserAgentService != null)
|
||||
{
|
||||
circuitCode = (uint)Util.RandomClass.Next(); ;
|
||||
aCircuit = MakeAgent(destination, account, avatar, session, secureSession, circuitCode, position, viewer);
|
||||
aCircuit = MakeAgent(destination, account, avatar, session, secureSession, circuitCode, position, clientIP.Address.ToString(), viewer, channel, mac, id0);
|
||||
success = LaunchAgentIndirectly(gatekeeper, destination, aCircuit, clientIP, out reason);
|
||||
if (!success && m_GridService != null)
|
||||
{
|
||||
@@ -694,7 +697,8 @@ namespace OpenSim.Services.LLLoginService
|
||||
}
|
||||
|
||||
private AgentCircuitData MakeAgent(GridRegion region, UserAccount account,
|
||||
AvatarData avatar, UUID session, UUID secureSession, uint circuit, Vector3 position, string viewer)
|
||||
AvatarData avatar, UUID session, UUID secureSession, uint circuit, Vector3 position,
|
||||
string ipaddress, string viewer, string channel, string mac, string id0)
|
||||
{
|
||||
AgentCircuitData aCircuit = new AgentCircuitData();
|
||||
|
||||
@@ -715,7 +719,11 @@ namespace OpenSim.Services.LLLoginService
|
||||
aCircuit.SecureSessionID = secureSession;
|
||||
aCircuit.SessionID = session;
|
||||
aCircuit.startpos = position;
|
||||
aCircuit.IPAddress = ipaddress;
|
||||
aCircuit.Viewer = viewer;
|
||||
aCircuit.Channel = channel;
|
||||
aCircuit.Mac = mac;
|
||||
aCircuit.Id0 = id0;
|
||||
SetServiceURLs(aCircuit, account);
|
||||
|
||||
return aCircuit;
|
||||
|
||||
Reference in New Issue
Block a user