Commit Graph

25 Commits (e09c8681ad5f6a645ef433e86166795a5c7dd762)

Author SHA1 Message Date
Justin Clark-Casey (justincc) 56dcb4e283 Add outbound URL filter to llHttpRequest() and osSetDynamicTextureURL*() script functions.
This is to address an issue where HTTP script functions could make calls to localhost and other endpoints inside the simulator's LAN.
By default, calls to all private addresses are now blocked as per http://en.wikipedia.org/wiki/Reserved_IP_addresses
If you require exceptions to this, configure [Network] OutboundDisallowForUserScriptsExcept in OpenSim.ini
2015-03-04 17:29:13 +00:00
Oren Hurvitz b8e22f02e7 Make sure Web streams are disposed after use 2014-01-31 00:44:22 +00:00
Justin Clark-Casey (justincc) 7cab41f422 refactor: replace verbose checks with String.IsNullOrEmpty where applicable.
Thanks to Kira for this patch from http://opensimulator.org/mantis/view.php?id=6845
2013-11-15 21:45:08 +00:00
Justin Clark-Casey (justincc) 44e9849ed1 Fix regression where llHTTPRequests which did not get an OK response returned 499 and the exception message in the http_response event rather than the actual response code and body.
This was a regression since commit 831e4c3 (Thu Apr 4 00:36:15 2013)
This commit also adds a regression test for this case, though this currently only works with Mono
This aims to address http://opensimulator.org/mantis/view.php?id=6704
2013-07-11 23:02:30 +01:00
Justin Clark-Casey (justincc) 148e46563f minor: fix mono compiler warning in ScriptsHttpRequests.cs 2013-04-10 00:07:58 +01:00
Justin Clark-Casey (justincc) f281a994e8 refactor: Simplify ScriptsHttpRequests.GetNextCompletedRequest to more simply iterate through pending requests without unnecessary checks. 2013-04-04 00:49:07 +01:00
Justin Clark-Casey (justincc) 831e4c3850 Fix bug where outstanding llHTTPRequests for scripts were not being aborted when they were deleted.
This was because AsyncCommandManager was handing an item ID to IHttpRequestModule.StopHttpRequest() rather than the expected request ID.
This commit also makes the http request asynchronous using BeginGetResponse() rather than doing this by launching a new thread
so that we can more safely abort it via HttpWebRequest.Abort() rather than aborting the thread itself.
This also renames StopHttpRequest() to StopHttpRequestsForScript() since any outstanding requests are now aborted and/or removed.
2013-04-04 00:36:15 +01:00
Kevin Cozens cbc9ae898c Added missing functionality (mainly custom headers) to llHTTPRequest. 2013-03-29 23:32:11 +00:00
Diva Canto 963b1e861c One more module converted: ScriptsHttpRequests. 2012-11-11 14:22:06 -08:00
Diva Canto 91a5c602e3 Revert "Added request.Proxy=null everywhere, as discussed in http://stackoverflow.com/questions/2519655/httpwebrequest-is-extremely-slow."
But the patch is here, in case anyone wants to try it.

This reverts commit 531edd51d8.
2012-09-30 07:48:03 -07:00
Diva Canto 531edd51d8 Added request.Proxy=null everywhere, as discussed in http://stackoverflow.com/questions/2519655/httpwebrequest-is-extremely-slow.
Thanks R.Gunther (rigun@rigutech.nl) https://lists.berlios.de/pipermail/opensim-users/2012-September/010986.html
2012-09-30 07:22:55 -07:00
Melanie ec299bfa87 Allow SmtpClients and other SSL users to work with our cert handler installed 2012-01-14 06:03:27 +00:00
BlueWall 87374274b9 Fix for failed http request status
Thanks "sendapatch" for fixes to llHTTPRequest status reporting.
2012-01-01 23:44:46 -05:00
Melanie eceedba23b Fix the cert validation handler so that it will not block other parts of
the server doing ssl successfully.
2011-05-13 12:02:49 +01:00
Justin Clark-Casey (justincc) 64dc7e9f14 minor: remove now inaccurate comment 2011-04-11 22:35:07 +01:00
Justin Clark-Casey (justincc) 3a98fb080a minor: adjust some spacing and indentation 2011-04-11 22:29:08 +01:00
E. Allen Soard 464fa45ec9 Implimented HTTP_VERIFY_CERT for llHttpRequest 2011-04-11 22:22:11 +01:00
John Hurliman 2519f071f2 Fixing a few compile errors in the previous commit 2009-10-06 02:50:59 -07:00
John Hurliman 387e9f7a7f * Creates Util.UTF8 and switches some references of Encoding.UTF8 to Util.UTF8 (not all references were switched since not all OpenSim libraries reference OpenSim.Framework)
* Shrinks the largest in-memory object, the LLRAW.HeightmapLookupValue struct (only used for exporting to LLRAW terrain files), to the minimum possible size. This seems to have the odd side effect of cutting the size of the two double[256,256] terrain objects in half. Possibly an alignment optimization?
2009-10-02 18:31:08 -07:00
Jeff Ames 840de6c036 Minor: Change OpenSim to OpenSimulator in older copyright headers and LICENSE.txt. 2009-06-01 06:37:14 +00:00
Melanie Thielker acfb5051cd Intermediate commit. WILL NOT COMPILE! 2009-05-04 20:15:39 +00:00
idb 23b247c519 Added the ability to set User-Agent in llHTTPRequest. No new default value has been set since having no User-Agent seems to work well but the facility is now available to set this if required. Using something based on the pattern of SLs User-Agent may well cause problems, not all web servers respond well to it. See the notes in the SL Wiki http://wiki.secondlife.com/wiki/LlHTTPRequest
Fixes Mantis #3143
2009-03-07 12:58:00 +00:00
Sean Dague 5959e42683 large scale fix for svn props after "the great refactor" 2009-02-12 18:59:45 +00:00
lbsa71 801da4346a * optimized usings. 2009-02-12 09:53:12 +00:00
Dr Scofield 180be7de07 this is step 2 of 2 of the OpenSim.Region.Environment refactor.
NOTHING has been deleted or moved off to forge at this point.  what
has happened is that OpenSim.Region.Environment.Modules has been split
in two:

- OpenSim.Region.CoreModules: all those modules that are either
  directly or indirectly referenced from  other  OpenSim packages, or
  that provide functionality that the OpenSim developer community
  considers core functionality:

      CoreModules/Agent/AssetTransaction
      CoreModules/Agent/Capabilities
      CoreModules/Agent/TextureDownload
      CoreModules/Agent/TextureSender
      CoreModules/Agent/TextureSender/Tests
      CoreModules/Agent/Xfer
      CoreModules/Avatar/AvatarFactory
      CoreModules/Avatar/Chat/ChatModule
      CoreModules/Avatar/Combat
      CoreModules/Avatar/Currency/SampleMoney
      CoreModules/Avatar/Dialog
      CoreModules/Avatar/Friends
      CoreModules/Avatar/Gestures
      CoreModules/Avatar/Groups
      CoreModules/Avatar/InstantMessage
      CoreModules/Avatar/Inventory
      CoreModules/Avatar/Inventory/Archiver
      CoreModules/Avatar/Inventory/Transfer
      CoreModules/Avatar/Lure
      CoreModules/Avatar/ObjectCaps
      CoreModules/Avatar/Profiles
      CoreModules/Communications/Local
      CoreModules/Communications/REST
      CoreModules/Framework/EventQueue
      CoreModules/Framework/InterfaceCommander
      CoreModules/Hypergrid
      CoreModules/InterGrid
      CoreModules/Scripting/DynamicTexture
      CoreModules/Scripting/EMailModules
      CoreModules/Scripting/HttpRequest
      CoreModules/Scripting/LoadImageURL
      CoreModules/Scripting/VectorRender
      CoreModules/Scripting/WorldComm
      CoreModules/Scripting/XMLRPC
      CoreModules/World/Archiver
      CoreModules/World/Archiver/Tests
      CoreModules/World/Estate
      CoreModules/World/Land
      CoreModules/World/Permissions
      CoreModules/World/Serialiser
      CoreModules/World/Sound
      CoreModules/World/Sun
      CoreModules/World/Terrain
      CoreModules/World/Terrain/DefaultEffects
      CoreModules/World/Terrain/DefaultEffects/bin
      CoreModules/World/Terrain/DefaultEffects/bin/Debug
      CoreModules/World/Terrain/Effects
      CoreModules/World/Terrain/FileLoaders
      CoreModules/World/Terrain/FloodBrushes
      CoreModules/World/Terrain/PaintBrushes
      CoreModules/World/Terrain/Tests
      CoreModules/World/Vegetation
      CoreModules/World/Wind
      CoreModules/World/WorldMap

- OpenSim.Region.OptionalModules: all those modules that are not core
  modules:

      OptionalModules/Avatar/Chat/IRC-stuff
      OptionalModules/Avatar/Concierge
      OptionalModules/Avatar/Voice/AsterixVoice
      OptionalModules/Avatar/Voice/SIPVoice
      OptionalModules/ContentManagementSystem
      OptionalModules/Grid/Interregion
      OptionalModules/Python
      OptionalModules/SvnSerialiser
      OptionalModules/World/NPC
      OptionalModules/World/TreePopulator
2009-02-10 13:10:57 +00:00