BetterHttpClient
BetterHttpClient copied to clipboard
No support for Host header
No implementation exists to be able to define the host header (situation where ip is known and multiple virtual servers exist) :-) GET \index.php HTTP1.1\r\nHost: XXXX\r\n XXXX is always requestUri.Host so impossible to let connect TCPclient on the ip (https:\45.45.45.45\index.php) then request a page with the virtualserver name.
do you mean set CustomHeaders ?
NameValueCollection headers = new NameValueCollection();
headers.Add("xxx", "xxx");
HttpClient client = new HttpClient(proxy)
{
CustomHeaders = headers,
};