Thank you, dmiles, for a patch that allows more differentiated script
permissions for YP scripts.trunk
parent
1c965b5a74
commit
22a533b675
|
@ -142,7 +142,7 @@ namespace OpenSim.Region.CoreModules.World.Permissions
|
||||||
private Dictionary<string, bool> GrantCS = new Dictionary<string, bool>();
|
private Dictionary<string, bool> GrantCS = new Dictionary<string, bool>();
|
||||||
private Dictionary<string, bool> GrantVB = new Dictionary<string, bool>();
|
private Dictionary<string, bool> GrantVB = new Dictionary<string, bool>();
|
||||||
private Dictionary<string, bool> GrantJS = new Dictionary<string, bool>();
|
private Dictionary<string, bool> GrantJS = new Dictionary<string, bool>();
|
||||||
|
private Dictionary<string, bool> GrantYP = new Dictionary<string, bool>();
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region IRegionModule Members
|
#region IRegionModule Members
|
||||||
|
@ -268,13 +268,25 @@ namespace OpenSim.Region.CoreModules.World.Permissions
|
||||||
}
|
}
|
||||||
|
|
||||||
grant = myConfig.GetString("GrantJS", "");
|
grant = myConfig.GetString("GrantJS", "");
|
||||||
if (grant.Length > 0) {
|
if (grant.Length > 0)
|
||||||
foreach (string uuidl in grant.Split(',')) {
|
{
|
||||||
|
foreach (string uuidl in grant.Split(','))
|
||||||
|
{
|
||||||
string uuid = uuidl.Trim(" \t".ToCharArray());
|
string uuid = uuidl.Trim(" \t".ToCharArray());
|
||||||
GrantJS.Add(uuid, true);
|
GrantJS.Add(uuid, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
grant = myConfig.GetString("GrantYP", "");
|
||||||
|
if (grant.Length > 0)
|
||||||
|
{
|
||||||
|
foreach (string uuidl in grant.Split(','))
|
||||||
|
{
|
||||||
|
string uuid = uuidl.Trim(" \t".ToCharArray());
|
||||||
|
GrantYP.Add(uuid, true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void HandleBypassPermissions(string module, string[] args)
|
public void HandleBypassPermissions(string module, string[] args)
|
||||||
|
@ -1784,7 +1796,14 @@ namespace OpenSim.Region.CoreModules.World.Permissions
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
if (GrantJS.Count == 0 || GrantJS.ContainsKey(ownerUUID.ToString())) {
|
if (GrantJS.Count == 0 || GrantJS.ContainsKey(ownerUUID.ToString()))
|
||||||
|
{
|
||||||
|
return (true);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case 4:
|
||||||
|
if (GrantYP.Count == 0 || GrantYP.ContainsKey(ownerUUID.ToString()))
|
||||||
|
{
|
||||||
return (true);
|
return (true);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue