aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2013-08-27 00:35:33 +0100
committerJustin Clark-Casey (justincc)2013-09-04 00:44:17 +0100
commitc7ded0618c303f8c24a91c83c2129292beebe466 (patch)
tree8a9321de4a47ac7b402ba0cf46ddb7c119dc3a32
parentFor a Hypergrid user, delay estate access checks until NewUserConnection() so... (diff)
downloadopensim-SC_OLD-c7ded0618c303f8c24a91c83c2129292beebe466.zip
opensim-SC_OLD-c7ded0618c303f8c24a91c83c2129292beebe466.tar.gz
opensim-SC_OLD-c7ded0618c303f8c24a91c83c2129292beebe466.tar.bz2
opensim-SC_OLD-c7ded0618c303f8c24a91c83c2129292beebe466.tar.xz
Also check user authorization if looking to upgrade from a child to a root agent.
Relevant if a child agent has been allowed into the region which should not be upgraded to a root agent.
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs13
1 files changed, 13 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index 8754024..3eaa8fd 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -3860,6 +3860,19 @@ namespace OpenSim.Region.Framework.Scenes
3860 // Let the SP know how we got here. This has a lot of interesting 3860 // Let the SP know how we got here. This has a lot of interesting
3861 // uses down the line. 3861 // uses down the line.
3862 sp.TeleportFlags = (TPFlags)teleportFlags; 3862 sp.TeleportFlags = (TPFlags)teleportFlags;
3863
3864 // We must carry out a further authorization check if there's an
3865 // attempt to make a child agent into a root agent, since SeeIntoRegion may have allowed a child
3866 // agent to login to a region where a full avatar would not be allowed.
3867 //
3868 // We determine whether this is a CreateAgent for a future non-child agent by inspecting
3869 // TeleportFlags, which will be default for a child connection. This relies on input from the source
3870 // region.
3871 if (sp.TeleportFlags != TPFlags.Default)
3872 {
3873 if (!AuthorizeUser(acd, false, out reason))
3874 return false;
3875 }
3863 3876
3864 if (sp.IsChildAgent) 3877 if (sp.IsChildAgent)
3865 { 3878 {