aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ClientStack
diff options
context:
space:
mode:
authorDiva Canto2010-01-18 16:34:23 -0800
committerDiva Canto2010-01-18 16:34:23 -0800
commit3d536944153d4931cf891d6a788a47484f3e6f4d (patch)
tree53802c5f051e8fbb089aeed02e0b9de760fabd8a /OpenSim/Region/ClientStack
parent* Added missing GatekeeperServiceConnector (diff)
downloadopensim-SC_OLD-3d536944153d4931cf891d6a788a47484f3e6f4d.zip
opensim-SC_OLD-3d536944153d4931cf891d6a788a47484f3e6f4d.tar.gz
opensim-SC_OLD-3d536944153d4931cf891d6a788a47484f3e6f4d.tar.bz2
opensim-SC_OLD-3d536944153d4931cf891d6a788a47484f3e6f4d.tar.xz
Go Home works. With security!!
Diffstat (limited to 'OpenSim/Region/ClientStack')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs20
1 files changed, 20 insertions, 0 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
index 3c4fa72..ffd2546 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLUDPServer.cs
@@ -38,6 +38,7 @@ using OpenMetaverse.Packets;
38using OpenSim.Framework; 38using OpenSim.Framework;
39using OpenSim.Framework.Statistics; 39using OpenSim.Framework.Statistics;
40using OpenSim.Region.Framework.Scenes; 40using OpenSim.Region.Framework.Scenes;
41using OpenSim.Services.Interfaces;
41using OpenMetaverse; 42using OpenMetaverse;
42 43
43using TokenBucket = OpenSim.Region.ClientStack.LindenUDP.TokenBucket; 44using TokenBucket = OpenSim.Region.ClientStack.LindenUDP.TokenBucket;
@@ -900,6 +901,25 @@ namespace OpenSim.Region.ClientStack.LindenUDP
900 901
901 if (!m_scene.TryGetClient(agentID, out existingClient)) 902 if (!m_scene.TryGetClient(agentID, out existingClient))
902 { 903 {
904 IHomeUsersSecurityService security = m_scene.RequestModuleInterface<IHomeUsersSecurityService>();
905 if (security != null)
906 {
907 IPEndPoint ep = security.GetEndPoint(sessionID);
908 if (ep != null && ep.ToString() != remoteEndPoint.ToString())
909 {
910 // uh-oh, this is fishy
911 m_log.WarnFormat("[LLUDPSERVER]: Agent {0} with session {1} connecting with unidentified end point. Refusing service.", agentID, sessionID);
912 m_log.WarnFormat("[LLUDPSERVER]: EP was {0}, now is {1}", ep.ToString(), remoteEndPoint.ToString());
913 return;
914 }
915 else if (ep != null)
916 {
917 // ok, you're home, welcome back
918 m_log.InfoFormat("LLUDPSERVER]: Agent {0} is coming back to this grid", agentID);
919 security.RemoveEndPoint(sessionID);
920 }
921 }
922
903 // Create the LLClientView 923 // Create the LLClientView
904 LLClientView client = new LLClientView(remoteEndPoint, m_scene, this, udpClient, sessionInfo, agentID, sessionID, circuitCode); 924 LLClientView client = new LLClientView(remoteEndPoint, m_scene, this, udpClient, sessionInfo, agentID, sessionID, circuitCode);
905 client.OnLogout += LogoutHandler; 925 client.OnLogout += LogoutHandler;