From d206721e2f8833f6c95fa9fda350f0187c24d34f Mon Sep 17 00:00:00 2001 From: Melanie Date: Tue, 9 Nov 2010 22:41:40 +0100 Subject: Add option SeeIntoBannedRegion to allow band to act like SL, where you can see in but not enter. Defaults to false, so no change. --- OpenSim/Region/Framework/Scenes/Scene.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/Framework/Scenes') diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index b6d9a02..a449cca 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs @@ -84,6 +84,7 @@ namespace OpenSim.Region.Framework.Scenes // TODO: need to figure out how allow client agents but deny // root agents when ACL denies access to root agent public bool m_strictAccessControl = true; + public bool m_seeIntoBannedRegion = false; public int MaxUndoCount = 5; public bool LoginsDisabled = true; public bool LoadingPrims; @@ -683,6 +684,7 @@ namespace OpenSim.Region.Framework.Scenes } m_strictAccessControl = startupConfig.GetBoolean("StrictAccessControl", m_strictAccessControl); + m_seeIntoBannedRegion = startupConfig.GetBoolean("SeeIntoBannedRegion", m_seeIntoBannedRegion); CombineRegions = startupConfig.GetBoolean("CombineContiguousRegions", false); m_generateMaptiles = startupConfig.GetBoolean("GenerateMaptiles", true); @@ -3688,7 +3690,7 @@ namespace OpenSim.Region.Framework.Scenes if (m_regInfo.EstateSettings != null) { - if (m_regInfo.EstateSettings.IsBanned(agent.AgentID)) + if ((!m_seeIntoBannedRegion) && m_regInfo.EstateSettings.IsBanned(agent.AgentID)) { m_log.WarnFormat("[CONNECTION BEGIN]: Denied access to: {0} ({1} {2}) at {3} because the user is on the banlist", agent.AgentID, agent.firstname, agent.lastname, RegionInfo.RegionName); @@ -3878,6 +3880,12 @@ namespace OpenSim.Region.Framework.Scenes // We have to wait until the viewer contacts this region after receiving EAC. // That calls AddNewClient, which finally creates the ScenePresence + if (m_regInfo.EstateSettings.IsBanned(cAgentData.AgentID)) + { + m_log.DebugFormat("[SCENE]: Denying root agent entry to {0}: banned", cAgentData.AgentID); + return false; + } + int num = m_sceneGraph.GetNumberOfScenePresences(); if (num >= RegionInfo.RegionSettings.AgentLimit) -- cgit v1.1