[SOLVED] [Unix port] examples/network/http_client_ssl.py only works for google.com?
Posted: Sat Apr 17, 2021 11:23 am
Both, Unix port MicroPython as well as python3, only work for example going against google.com -- any other https target does not:
OSError -40 for "en.wikipedia.org".
Domain not found for "nytimes.com":
Bad request for "stamm-wilbrandt.de":
What is wrong with the example or with MicroPython?
OSError -40 for "en.wikipedia.org".
Domain not found for "nytimes.com":
Code: Select all
...
<_SSLSocket 11f9cf0>
b'HTTP/1.1 500 Domain Not Found\r\nConnection: close\r\nContent-Length: 221\r\nServer: Varnish\r\nRetry-After: 0\r\ncontent-type: text/html\r\nCache-Control: private, no-cache\r\nX-Served-By: cache-fra19157-FRA\r\nAccept-Ranges: bytes\r\nDate: Sat, 17 Apr 2021 11:21:18 GMT\r\nVia: 1.1 varnish\r\n\r\n\n<html>\n<head>\n<title>Fastly error: unknown domain </title>\n</head>\n<body>\n<p>Fastly error: unknown domain: . Please check that this domain has been added to a service.</p>\n<p>Details: cache-fra19157-FRA</p></body></html>'
$
Bad request for "stamm-wilbrandt.de":
Code: Select all
...
<_SSLSocket 5c65f8>
b'HTTP/1.1 400 Bad Request\r\nServer: nginx\r\nDate: Sat, 17 Apr 2021 11:24:55 GMT\r\nContent-Type: text/html; charset=iso-8859-1\r\nContent-Length: 226\r\nConnection: close\r\n\r\n<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">\n<html><head>\n<title>400 Bad Request</title>\n</head><body>\n<h1>Bad Request</h1>\n<p>Your browser sent a request that this server could not understand.<br />\n</p>\n</body></html>\n'
$