aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Scene.cs
diff options
context:
space:
mode:
authordiva2009-02-11 21:07:41 +0000
committerdiva2009-02-11 21:07:41 +0000
commitb6e7e5ed424c4c26c3f86f8decbd2b15a5ab90e1 (patch)
treec7b8ebb8ce301eaacdb37929330252667143eddf /OpenSim/Region/Framework/Scenes/Scene.cs
parent* minor: remove some mono compiler warnings (diff)
downloadopensim-SC_OLD-b6e7e5ed424c4c26c3f86f8decbd2b15a5ab90e1.zip
opensim-SC_OLD-b6e7e5ed424c4c26c3f86f8decbd2b15a5ab90e1.tar.gz
opensim-SC_OLD-b6e7e5ed424c4c26c3f86f8decbd2b15a5ab90e1.tar.bz2
opensim-SC_OLD-b6e7e5ed424c4c26c3f86f8decbd2b15a5ab90e1.tar.xz
Enforce estate bans on Teleports.
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs28
1 files changed, 27 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 18245e5..848b497 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -2286,6 +2286,32 @@ namespace OpenSim.Region.Framework.Scenes
2286 2286
2287 public override void AddNewClient(IClientAPI client) 2287 public override void AddNewClient(IClientAPI client)
2288 { 2288 {
2289 if (m_regInfo.EstateSettings.IsBanned(client.AgentId))
2290 {
2291 m_log.WarnFormat("[CONNECTION BEGIN]: Denied access to: {0} ({1} {2}) at {3} because the user is on the banlist",
2292 client.AgentId, client.FirstName, client.LastName, RegionInfo.RegionName);
2293 client.SendAlertMessage("Denied access to region " + RegionInfo.RegionName + ". You have been banned from that region.");
2294 try
2295 {
2296 IEventQueue eq = RequestModuleInterface<IEventQueue>();
2297 if (eq != null)
2298 {
2299 eq.DisableSimulator(RegionInfo.RegionHandle, client.AgentId);
2300 }
2301 else
2302 client.SendShutdownConnectionNotice();
2303
2304 client.Close(false);
2305 CapsModule.RemoveCapsHandler(client.AgentId);
2306 m_authenticateHandler.RemoveCircuit(client.CircuitCode);
2307 }
2308 catch (Exception e)
2309 {
2310 m_log.DebugFormat("[SCENE]: Exception while closing banned client {0} {1}: {2}", client.FirstName, client.LastName, e.Message);
2311 }
2312 }
2313
2314
2289 SubscribeToClientEvents(client); 2315 SubscribeToClientEvents(client);
2290 ScenePresence presence; 2316 ScenePresence presence;
2291 2317
@@ -2803,7 +2829,7 @@ namespace OpenSim.Region.Framework.Scenes
2803 if (m_regInfo.EstateSettings.IsBanned(agent.AgentID)) 2829 if (m_regInfo.EstateSettings.IsBanned(agent.AgentID))
2804 { 2830 {
2805 m_log.WarnFormat( 2831 m_log.WarnFormat(
2806 "[CONNECTION BEGIN]: Denied access to: {0} at {1} because the user is on the region banlist", 2832 "[CONNECTION BEGIN]: Incoming user {0} at {1} is on the region banlist",
2807 agent.AgentID, RegionInfo.RegionName); 2833 agent.AgentID, RegionInfo.RegionName);
2808 } 2834 }
2809 2835