aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Scene.cs
diff options
context:
space:
mode:
authorMelanie2010-01-09 15:58:18 +0000
committerMelanie2010-01-09 15:58:18 +0000
commit673a52fa7a0cef508396cfc2185825e72cf96507 (patch)
tree75849e2d511cac278ba7d9fc591196d325d8d711 /OpenSim/Region/Framework/Scenes/Scene.cs
parentFix up the weird Lindenish "setaccess" message. Talk about strange.... (diff)
downloadopensim-SC-673a52fa7a0cef508396cfc2185825e72cf96507.zip
opensim-SC-673a52fa7a0cef508396cfc2185825e72cf96507.tar.gz
opensim-SC-673a52fa7a0cef508396cfc2185825e72cf96507.tar.bz2
opensim-SC-673a52fa7a0cef508396cfc2185825e72cf96507.tar.xz
Implement the groups module query to make the estate allowed groups work
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs29
1 files changed, 28 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 764ac60..183d811 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -3525,8 +3525,35 @@ namespace OpenSim.Region.Framework.Scenes
3525 return false; 3525 return false;
3526 } 3526 }
3527 3527
3528 IGroupsModule groupsModule =
3529 RequestModuleInterface<IGroupsModule>();
3530
3531 List<UUID> agentGroups = new List<UUID>();
3532
3533 if (groupsModule != null)
3534 {
3535 GroupMembershipData[] GroupMembership =
3536 groupsModule.GetMembershipData(agent.AgentID);
3537
3538 for (int i = 0; i < GroupMembership.Length; i++)
3539 agentGroups.Add(GroupMembership[i].GroupID);
3540 }
3541
3542 bool groupAccess = false;
3543 UUID[] estateGroups = m_regInfo.EstateSettings.EstateGroups;
3544
3545 foreach (UUID group in estateGroups)
3546 {
3547 if (agentGroups.Contains(group))
3548 {
3549 groupAccess = true;
3550 break;
3551 }
3552 }
3553
3528 if (!m_regInfo.EstateSettings.PublicAccess && 3554 if (!m_regInfo.EstateSettings.PublicAccess &&
3529 !m_regInfo.EstateSettings.HasAccess(agent.AgentID)) 3555 !m_regInfo.EstateSettings.HasAccess(agent.AgentID) &&
3556 !groupAccess)
3530 { 3557 {
3531 m_log.WarnFormat("[CONNECTION BEGIN]: Denied access to: {0} ({1} {2}) at {3} because the user does not have access to the estate", 3558 m_log.WarnFormat("[CONNECTION BEGIN]: Denied access to: {0} ({1} {2}) at {3} because the user does not have access to the estate",
3532 agent.AgentID, agent.firstname, agent.lastname, RegionInfo.RegionName); 3559 agent.AgentID, agent.firstname, agent.lastname, RegionInfo.RegionName);