我可以通过http连接,但无法连接https。
HttpRequestException消息:
发送请求时发生错误。 System.Net.WebExceptionStatus.TrustFailure
HttpClientHandler clienthandler = new HttpClientHandler();
HttpClient client = new HttpClient(clienthandler);
HttpRequestMessage req = new HttpRequestMessage(HttpMethod.Post, "https://www.google.com.hk/");
req.Headers.Referrer = new Uri("https://www.google.com.hk/");
HttpResponseMessage mes = await client.SendAsync(req);