Remove OpenID cookie check (agni_sl_session_id) from *SetContentType Remove commented out second llSetContentType thats the same as osSetContentType anyway

Signed-off-by: UbitUmarov <ajlduarte@sapo.pt>
This commit is contained in:
uriesk
2018-12-08 19:26:17 +01:00
committed by UbitUmarov
parent 1610595697
commit 34b7d7ec6e
2 changed files with 0 additions and 44 deletions

View File

@@ -69,7 +69,6 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
public int startTime;
public bool responseSent;
public string uri;
public bool allowResponseType = false;
public UUID hostID;
public Scene scene;
}
@@ -383,10 +382,6 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
{
string responseBody = body;
// If we have no OpenID from built-in browser, disable this
if (!urlData.requests[request].allowResponseType)
urlData.requests[request].responseType = "text/plain";
if (urlData.requests[request].responseType.Equals("text/plain"))
{
string value;
@@ -703,32 +698,6 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp
string key = (string)header.Key;
string value = (string)header.Value;
requestData.headers.Add(key, value);
if (key == "cookie")
{
string[] parts = value.Split(new char[] {'='});
if (parts[0] == "agni_sl_session_id" && parts.Length > 1)
{
string cookie = Uri.UnescapeDataString(parts[1]);
string[] crumbs = cookie.Split(new char[] {':'});
UUID owner;
if (crumbs.Length == 2 && UUID.TryParse(crumbs[0], out owner))
{
if (crumbs[1].Length == 32)
{
Scene scene = requestData.scene;
if (scene != null)
{
SceneObjectPart host = scene.GetSceneObjectPart(requestData.hostID);
if (host != null)
{
if (host.OwnerID == owner)
requestData.allowResponseType = true;
}
}
}
}
}
}
}
foreach (DictionaryEntry de in request)
{