HttpClient Issues

First I would like to say excellent job on the network stack so far.

I am using version .45 and having an issue with the HttpClient class. Using the Basic Wifi sample on github without changes works fine.

However if I do this for example:

GetWebPageViaHttpClient(“https://microsoft.com/”).Wait();

I get an exception “System.Net.Sockets.SocketException: No such host is known”.

The same thing works fine in a desktop application. In addition If I do this in the meadow app:

var addresses = Dns.GetHostAddresses(“microsoft.com”);

It seems to be able to resolve the address no problem.

Thanks,
Eric

It may be the https that is the problem. Could you try http to see if that works. I think Google still accept requests over http.

Regards,
Mark

Thanks Mark.

Yes http://www.gooogle.com/ worked fine.

Is this a known issue with the TLS implementation right now? I also get “System.IO.IOException: TLS initial zation or handshake failed” on some sites.

I’ve been able to work around some of this by just specifying an IP Address and setting the Host header manually for now. In case anyone else is having an issue.