CA-140647: Customer is not getting the list of updates when ever they select the "Check for Updates" option from the tools menu within Xencenter.

-Added 'Host:' to HTTP headers for all the HTTP GET and PUT requests sent by XenCenter.
This change will presumably fix network issues occurring when going through certain corporate firewalls/proxies.

Signed-off-by: Gabor Apati-Nagy <gabor.apati-nagy@citrix.com>
This commit is contained in:
Gabor Apati-Nagy 2014-07-16 17:37:40 +01:00
parent 104d4445e1
commit 58649f9916

View File

@ -413,13 +413,15 @@ namespace XenAPI
{
return DO_HTTP(uri, proxy, false, timeout_ms,
string.Format("PUT {0} HTTP/1.0", uri.PathAndQuery),
string.Format("Host: {0}", uri.Host),
string.Format("Content-Length: {0}", ContentLength));
}
public static Stream GET(Uri uri, IWebProxy proxy, int timeout_ms)
{
return DO_HTTP(uri, proxy, false, timeout_ms,
string.Format("GET {0} HTTP/1.0", uri.PathAndQuery));
string.Format("GET {0} HTTP/1.0", uri.PathAndQuery),
string.Format("Host: {0}", uri.Host));
}
/// <summary>