Patches #9143 and #9144 (Mantis #1723)

Changes the permissions module to make scripts permissive only when intended
Adds security checks to asset transfers to prevent hacked clients fron
requesting script sources.
Adds security checks to llClientView to verify all aspects of ownership
and permissions for inventory based script retrieval.
This commit is contained in:
Melanie Thielker
2008-07-12 06:24:43 +00:00
parent 13399ff439
commit f629fdb88d
3 changed files with 68 additions and 2 deletions

View File

@@ -445,7 +445,10 @@ namespace OpenSim.Framework.Communications.Cache
req.NumPackets = CalculateNumPackets(assetInf.Data);
RequestedAssets.Remove(assetInf.FullID);
AssetRequests.Add(req);
// If it's a direct request for a script, drop it
// because it's a hacked client
if(req.AssetRequestSource != 2 || assetInf.Type != 10)
AssetRequests.Add(req);
}
}
}
@@ -609,6 +612,10 @@ namespace OpenSim.Framework.Communications.Cache
return;
}
// Scripts cannot be retrieved by direct request
if (transferRequest.TransferInfo.SourceType == 2 && asset.Type == 10)
return;
// The asset is knosn to exist and is in our cache, so add it to the AssetRequests list
AssetRequest req = new AssetRequest();
req.RequestUser = userInfo;