Core: Socket::SSLServerNameIndicator, used in HttpRequest; fixes problems with connecting to some https server

git-svn-id: svn://ultimatepp.org/upp/trunk@10990 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2017-04-08 21:32:22 +00:00
parent 7b15d8a262
commit c9bb56577b
5 changed files with 32 additions and 4 deletions

View file

@ -446,13 +446,15 @@ void HttpRequest::Start()
p = ssl ? DEFAULT_HTTPS_PORT : DEFAULT_HTTP_PORT;
String h = use_proxy ? ssl ? ssl_proxy_host : proxy_host : host;
LLOG("Using " << (use_proxy ? "proxy " : "") << h << ":" << p);
SSLServerNameIndication(host);
StartPhase(DNS);
if(IsNull(GetTimeout()) && timeout == INT_MAX) {
if(WhenWait) {
addrinfo.Start(h, p);
while(addrinfo.InProgress()) {
Sleep(GetWaitStep());
Sleep(GetWaitStep());
WhenWait();
if(msecs(start_time) >= timeout)
break;