mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 17:05:55 +08:00
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:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user