Diva Canto 2012-09-30 07:22:55 -07:00
parent 14a4b146bf
commit 531edd51d8
25 changed files with 41 additions and 8 deletions

View File

@ -46,8 +46,8 @@ namespace OpenSim.ConsoleClient
WebRequest request = WebRequest.Create(requestUrl);
WebResponse response = null;
request.Proxy = null;
request.Method = "POST";
request.ContentType = "application/x-www-form-urlencoded";
byte[] buffer = Encoding.ASCII.GetBytes(data);

View File

@ -306,6 +306,7 @@ namespace OpenSim.Framework.Communications
_request.ContentType = "application/xml";
_request.Timeout = 200000;
_request.Method = RequestMethod;
_request.Proxy = null;
_asyncException = null;
// IAsyncResult responseAsyncResult = _request.BeginGetResponse(new AsyncCallback(ResponseIsReadyDelegate), _request);
@ -365,6 +366,7 @@ namespace OpenSim.Framework.Communications
_request.ContentType = "application/xml";
_request.Timeout = 900000;
_request.Method = RequestMethod;
_request.Proxy = null;
_asyncException = null;
_request.ContentLength = src.Length;

View File

@ -65,6 +65,7 @@ namespace OpenSim.Framework.Configuration.HTTP
byte[] buf = new byte[8192];
HttpWebRequest request =
(HttpWebRequest) WebRequest.Create(remoteConfigSettings.baseConfigURL + configFileName);
request.Proxy = null;
HttpWebResponse response = (HttpWebResponse) request.GetResponse();
Stream resStream = response.GetResponseStream();

View File

@ -70,6 +70,7 @@ namespace OpenSim.Framework.RegionLoader.Web
int regionCount = 0;
HttpWebRequest webRequest = (HttpWebRequest) WebRequest.Create(url);
webRequest.Timeout = 30000; //30 Second Timeout
webRequest.Proxy = null;
m_log.DebugFormat("[WEBLOADER]: Sending download request to {0}", url);
try

View File

@ -50,6 +50,7 @@ namespace OpenSim.Framework.Servers.HttpServer
WebRequest request = WebRequest.Create(requestUrl);
request.Method = verb;
request.Proxy = null;
request.ContentType = "text/xml";
MemoryStream buffer = new MemoryStream();

View File

@ -57,6 +57,7 @@ namespace OpenSim.Framework.Servers.HttpServer
WebRequest request = WebRequest.Create(requestUrl);
request.Method = verb;
request.Proxy = null;
request.ContentType = "text/xml";
request.Timeout = 10000;

View File

@ -74,6 +74,7 @@ namespace OpenSim.Framework.Servers.HttpServer
WebRequest request = WebRequest.Create(requestUrl);
request.Method = verb;
request.Proxy = null;
request.ContentType = "text/xml";
request.Timeout = 20000;
@ -139,6 +140,7 @@ namespace OpenSim.Framework.Servers.HttpServer
WebRequest request = WebRequest.Create(requestUrl);
request.Method = verb;
request.Proxy = null;
request.ContentType = "text/xml";
request.Timeout = 10000;

View File

@ -88,6 +88,7 @@ namespace OpenSim.Framework
httpWebRequest.ReadWriteTimeout = readWriteTimeoutMS;
httpWebRequest.Timeout = timeoutMS;
httpWebRequest.KeepAlive = false;
httpWebRequest.Proxy = null;
return httpWebRequest;
}

View File

@ -171,6 +171,7 @@ namespace OpenSim.Framework
request.Method = method;
request.Timeout = timeout;
request.KeepAlive = false;
request.Proxy = null;
request.MaximumAutomaticRedirections = 10;
request.ReadWriteTimeout = timeout / 4;
request.Headers[OSHeaderRequestID] = reqnum.ToString();
@ -350,6 +351,7 @@ namespace OpenSim.Framework
request.Method = "POST";
request.Timeout = timeout;
request.KeepAlive = false;
request.Proxy = null;
request.MaximumAutomaticRedirections = 10;
request.ReadWriteTimeout = timeout / 4;
request.Headers[OSHeaderRequestID] = reqnum.ToString();
@ -730,6 +732,7 @@ namespace OpenSim.Framework
Type type = typeof(TRequest);
WebRequest request = WebRequest.Create(requestUrl);
request.Proxy = null;
WebResponse response = null;
TResponse deserial = default(TResponse);
XmlSerializer deserializer = new XmlSerializer(typeof(TResponse));
@ -924,6 +927,7 @@ namespace OpenSim.Framework
WebRequest request = WebRequest.Create(requestUrl);
request.Method = verb;
request.Proxy = null;
string respstring = String.Empty;
using (MemoryStream buffer = new MemoryStream())
@ -1051,6 +1055,7 @@ namespace OpenSim.Framework
WebRequest request = WebRequest.Create(requestUrl);
request.Method = verb;
request.Proxy = null;
MemoryStream buffer = null;
if ((verb == "POST") || (verb == "PUT"))

View File

@ -384,6 +384,7 @@ namespace OpenSim.Region.CoreModules.Scripting.HttpRequest
Request = (HttpWebRequest) WebRequest.Create(Url);
Request.Method = HttpMethod;
Request.ContentType = HttpMIMEType;
Request.Proxy = null;
if(!HttpVerifyCert)
{

View File

@ -161,6 +161,8 @@ namespace OpenSim.Region.CoreModules.Scripting.LoadImageURL
request.Proxy = new WebProxy(m_proxyurl, true);
}
}
else
request.Proxy = null;
RequestState state = new RequestState((HttpWebRequest) request, requestID);
// IAsyncResult result = request.BeginGetResponse(new AsyncCallback(HttpRequestReturn), state);

View File

@ -826,6 +826,7 @@ namespace OpenSim.Region.CoreModules.Scripting.VectorRender
try
{
WebRequest request = HttpWebRequest.Create(url);
request.Proxy = null;
//Ckrinke: Comment out for now as 'str' is unused. Bring it back into play later when it is used.
//Ckrinke Stream str = null;
HttpWebResponse response = (HttpWebResponse)(request).GetResponse();

View File

@ -110,6 +110,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver
request.ContentLength = 0;
request.KeepAlive = false;
request.Proxy = null;
WebResponse response = request.GetResponse();
Stream file = response.GetResponseStream();

View File

@ -352,6 +352,7 @@ namespace OpenSim.Region.CoreModules.World.Terrain
request.ContentLength = 0;
request.KeepAlive = false;
request.Proxy = null;
WebResponse response = request.GetResponse();
Stream file = response.GetResponseStream();

View File

@ -819,6 +819,7 @@ namespace OpenSim.Region.CoreModules.World.WorldMap
mapitemsrequest.Method = "POST";
mapitemsrequest.ContentType = "application/xml+llsd";
mapitemsrequest.Proxy = null;
OSDMap RAMap = new OSDMap();
// string RAMapString = RAMap.ToString();

View File

@ -386,7 +386,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Concierge
updatePost.ContentType = "text/xml";
updatePost.ContentLength = payload.Length;
updatePost.UserAgent = "OpenSim.Concierge";
updatePost.Proxy = null;
BrokerState bs = new BrokerState(uri, payload, updatePost);
bs.Timer = new Timer(delegate(object state)

View File

@ -541,6 +541,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.FreeSwitchVoice
forwardreq.Method = method;
forwardreq.ContentType = contenttype;
forwardreq.KeepAlive = false;
forwardreq.Proxy = null;
if (method == "POST")
{

View File

@ -1119,6 +1119,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.Voice.VivoxVoice
// We are sending just parameters, no content
req.ContentLength = 0;
req.Proxy = null;
// Send request and retrieve the response
rsp = (HttpWebResponse)req.GetResponse();

View File

@ -1150,6 +1150,7 @@ namespace Nwc.XmlRpc
request.ContentType = "text/xml";
request.AllowWriteStreamBuffering = true;
request.KeepAlive = !_disableKeepAlive;
request.Proxy = null;
Stream stream = request.GetRequestStream();
XmlTextWriter xml = new XmlTextWriter(stream, Encoding.ASCII);

View File

@ -280,6 +280,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
WebRequest request = WebRequest.Create(m_uri);
request.Method = request_method;
request.ContentType = content_type;
request.Proxy = null;
Stream os = null;
try

View File

@ -77,6 +77,7 @@ namespace OpenSim.Services.Connectors
public virtual string Helo()
{
HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create(m_ServerURI);
req.Proxy = null;
// Eventually we need to switch to HEAD
/* req.Method = "HEAD"; */

View File

@ -125,6 +125,7 @@ namespace OpenSim.Services.Connectors.Hypergrid
AgentCreateRequest.Method = "POST";
AgentCreateRequest.ContentType = "application/json";
AgentCreateRequest.Timeout = 10000;
AgentCreateRequest.Proxy = null;
//AgentCreateRequest.KeepAlive = false;
//AgentCreateRequest.Headers.Add("Authorization", authKey);

View File

@ -107,6 +107,7 @@ namespace OpenSim.Services.Connectors
helloNeighbourRequest.Method = "POST";
helloNeighbourRequest.ContentType = "application/json";
helloNeighbourRequest.Timeout = 10000;
helloNeighbourRequest.Proxy = null;
// Fill it in
OSDMap args = null;

View File

@ -184,6 +184,7 @@ namespace OpenSim.Services.Connectors.SimianGrid
{
HttpWebRequest request = UntrustedHttpWebRequest.Create(url);
request.Method = "HEAD";
request.Proxy = null;
using (WebResponse response = request.GetResponse())
{
@ -339,6 +340,7 @@ namespace OpenSim.Services.Connectors.SimianGrid
// Simian does not require the asset ID to be in the URL because it's in the post data.
// By appending it to the URL also, we allow caching proxies (squid) to invalidate asset URLs
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(m_serverUrl + asset.FullID.ToString());
request.Proxy = null;
HttpWebResponse response = MultipartForm.Post(request, postParameters);
using (Stream responseStream = response.GetResponseStream())
@ -427,6 +429,7 @@ namespace OpenSim.Services.Connectors.SimianGrid
{
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(url);
request.Method = "DELETE";
request.Proxy = null;
using (HttpWebResponse response = (HttpWebResponse)request.GetResponse())
{
@ -460,6 +463,7 @@ namespace OpenSim.Services.Connectors.SimianGrid
try
{
HttpWebRequest request = UntrustedHttpWebRequest.Create(url);
request.Proxy = null;
using (WebResponse response = request.GetResponse())
{

View File

@ -212,6 +212,7 @@ namespace OpenSim.Region.OptionalModules.Simian
HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(m_serverUrl);
request.Timeout = 20000;
request.ReadWriteTimeout = 5000;
request.Proxy = null;
using (HttpWebResponse response = MultipartForm.Post(request, postParameters))
{