mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 00:46:02 +08:00
Security fix: Allow only textures to be fetched using HTTP texture cap
This commit is contained in:
committed by
Melanie
parent
1e1485de5b
commit
854a8b9172
@@ -131,6 +131,12 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps
|
||||
|
||||
if (texture != null)
|
||||
{
|
||||
if (texture.Type != (sbyte)AssetType.Texture)
|
||||
{
|
||||
httpResponse.StatusCode = (int)System.Net.HttpStatusCode.NotFound;
|
||||
httpResponse.Send();
|
||||
return null;
|
||||
}
|
||||
SendTexture(httpRequest, httpResponse, texture);
|
||||
}
|
||||
else
|
||||
@@ -147,6 +153,12 @@ namespace OpenSim.Region.CoreModules.Avatar.ObjectCaps
|
||||
|
||||
if (texture != null)
|
||||
{
|
||||
if (texture.Type != (sbyte)AssetType.Texture)
|
||||
{
|
||||
httpResponse.StatusCode = (int)System.Net.HttpStatusCode.NotFound;
|
||||
httpResponse.Send();
|
||||
return null;
|
||||
}
|
||||
SendTexture(httpRequest, httpResponse, texture);
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user