diff options
Diffstat (limited to 'OpenSim/Region/CoreModules')
3 files changed, 32 insertions, 13 deletions
diff --git a/OpenSim/Region/CoreModules/Scripting/HttpRequest/ScriptsHttpRequests.cs b/OpenSim/Region/CoreModules/Scripting/HttpRequest/ScriptsHttpRequests.cs index 57dc556..b499b19 100644 --- a/OpenSim/Region/CoreModules/Scripting/HttpRequest/ScriptsHttpRequests.cs +++ b/OpenSim/Region/CoreModules/Scripting/HttpRequest/ScriptsHttpRequests.cs | |||
@@ -110,7 +110,7 @@ namespace OpenSim.Region.CoreModules.Scripting.HttpRequest | |||
110 | 110 | ||
111 | public HttpRequestModule() | 111 | public HttpRequestModule() |
112 | { | 112 | { |
113 | ServicePointManager.ServerCertificateValidationCallback +=ValidateServerCertificate; | 113 | // ServicePointManager.ServerCertificateValidationCallback +=ValidateServerCertificate; |
114 | } | 114 | } |
115 | 115 | ||
116 | public static bool ValidateServerCertificate( | 116 | public static bool ValidateServerCertificate( |
diff --git a/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs b/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs index 11fc513..5f72733 100644 --- a/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs +++ b/OpenSim/Region/CoreModules/Scripting/LSLHttp/UrlModule.cs | |||
@@ -258,7 +258,7 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp | |||
258 | string uri = "/lslhttp/" + urlcode.ToString() + "/"; | 258 | string uri = "/lslhttp/" + urlcode.ToString() + "/"; |
259 | 259 | ||
260 | PollServiceEventArgs args | 260 | PollServiceEventArgs args |
261 | = new PollServiceEventArgs(HttpRequestHandler, uri, HasEvents, GetEvents, NoEvents, urlcode, 25000); | 261 | = new PollServiceEventArgs(HttpRequestHandler, uri, HasEvents, GetEvents, NoEvents, Drop, urlcode, 25000); |
262 | args.Type = PollServiceEventArgs.EventType.LslHttp; | 262 | args.Type = PollServiceEventArgs.EventType.LslHttp; |
263 | m_HttpServer.AddPollServiceHTTPHandler(uri, args); | 263 | m_HttpServer.AddPollServiceHTTPHandler(uri, args); |
264 | 264 | ||
@@ -316,7 +316,7 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp | |||
316 | string uri = "/lslhttps/" + urlcode.ToString() + "/"; | 316 | string uri = "/lslhttps/" + urlcode.ToString() + "/"; |
317 | 317 | ||
318 | PollServiceEventArgs args | 318 | PollServiceEventArgs args |
319 | = new PollServiceEventArgs(HttpRequestHandler, uri, HasEvents, GetEvents, NoEvents, urlcode, 25000); | 319 | = new PollServiceEventArgs(HttpRequestHandler, uri, HasEvents, GetEvents, NoEvents, Drop, urlcode, 25000); |
320 | args.Type = PollServiceEventArgs.EventType.LslHttp; | 320 | args.Type = PollServiceEventArgs.EventType.LslHttp; |
321 | m_HttpsServer.AddPollServiceHTTPHandler(uri, args); | 321 | m_HttpsServer.AddPollServiceHTTPHandler(uri, args); |
322 | 322 | ||
@@ -570,6 +570,28 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp | |||
570 | } | 570 | } |
571 | } | 571 | } |
572 | } | 572 | } |
573 | |||
574 | protected void Drop(UUID requestID, UUID sessionID) | ||
575 | { | ||
576 | UrlData url = null; | ||
577 | lock (m_RequestMap) | ||
578 | { | ||
579 | if (m_RequestMap.ContainsKey(requestID)) | ||
580 | { | ||
581 | url = m_RequestMap[requestID]; | ||
582 | m_RequestMap.Remove(requestID); | ||
583 | if(url != null) | ||
584 | { | ||
585 | lock (url.requests) | ||
586 | { | ||
587 | if(url.requests.ContainsKey(requestID)) | ||
588 | url.requests.Remove(requestID); | ||
589 | } | ||
590 | } | ||
591 | } | ||
592 | } | ||
593 | } | ||
594 | |||
573 | protected Hashtable GetEvents(UUID requestID, UUID sessionID) | 595 | protected Hashtable GetEvents(UUID requestID, UUID sessionID) |
574 | { | 596 | { |
575 | UrlData url = null; | 597 | UrlData url = null; |
@@ -729,9 +751,9 @@ namespace OpenSim.Region.CoreModules.Scripting.LSLHttp | |||
729 | else | 751 | else |
730 | { | 752 | { |
731 | queryString = queryString + val + "&"; | 753 | queryString = queryString + val + "&"; |
732 | } | ||
733 | } | 754 | } |
734 | } | 755 | } |
756 | } | ||
735 | if (queryString.Length > 1) | 757 | if (queryString.Length > 1) |
736 | queryString = queryString.Substring(0, queryString.Length - 1); | 758 | queryString = queryString.Substring(0, queryString.Length - 1); |
737 | 759 | ||
diff --git a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs index a2c7c83..c7e58e5 100644 --- a/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs +++ b/OpenSim/Region/CoreModules/World/Land/LandManagementModule.cs | |||
@@ -1719,26 +1719,23 @@ namespace OpenSim.Region.CoreModules.World.Land | |||
1719 | 1719 | ||
1720 | private void EventManagerOnRegisterCaps(UUID agentID, Caps caps) | 1720 | private void EventManagerOnRegisterCaps(UUID agentID, Caps caps) |
1721 | { | 1721 | { |
1722 | //string capsBase = "/CAPS/" + UUID.Random(); | 1722 | string cap = "/CAPS/" + UUID.Random(); |
1723 | string capsBase = "/CAPS/" + caps.CapsObjectPath; | ||
1724 | caps.RegisterHandler( | 1723 | caps.RegisterHandler( |
1725 | "RemoteParcelRequest", | 1724 | "RemoteParcelRequest", |
1726 | new RestStreamHandler( | 1725 | new RestStreamHandler( |
1727 | "POST", | 1726 | "POST", cap, |
1728 | capsBase, | ||
1729 | (request, path, param, httpRequest, httpResponse) | 1727 | (request, path, param, httpRequest, httpResponse) |
1730 | => RemoteParcelRequest(request, path, param, agentID, caps), | 1728 | => RemoteParcelRequest(request, path, param, agentID, caps), |
1731 | "RemoteParcelRequest", | 1729 | "RemoteParcelRequest", |
1732 | agentID.ToString())); | 1730 | agentID.ToString())); |
1733 | 1731 | ||
1734 | UUID parcelCapID = UUID.Random(); | 1732 | cap = "/CAPS/" + UUID.Random(); |
1735 | caps.RegisterHandler( | 1733 | caps.RegisterHandler( |
1736 | "ParcelPropertiesUpdate", | 1734 | "ParcelPropertiesUpdate", |
1737 | new RestStreamHandler( | 1735 | new RestStreamHandler( |
1738 | "POST", | 1736 | "POST", cap, |
1739 | "/CAPS/" + parcelCapID, | 1737 | (request, path, param, httpRequest, httpResponse) |
1740 | (request, path, param, httpRequest, httpResponse) | 1738 | => ProcessPropertiesUpdate(request, path, param, agentID, caps), |
1741 | => ProcessPropertiesUpdate(request, path, param, agentID, caps), | ||
1742 | "ParcelPropertiesUpdate", | 1739 | "ParcelPropertiesUpdate", |
1743 | agentID.ToString())); | 1740 | agentID.ToString())); |
1744 | } | 1741 | } |