aboutsummaryrefslogtreecommitdiffstats
path: root/net/http.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2020-08-17 23:01:14 +0200
committerKim Alvefur <zash@zash.se>2020-08-17 23:01:14 +0200
commit93d0d13fbb20af44330260c2884d1358efc3e653 (patch)
tree865d487db4a9ea6ec76ce093bfd405bfb76a87ff /net/http.lua
parent5da7c3dac30393ae30505fac2f641f9e04ea5458 (diff)
downloadprosody-93d0d13fbb20af44330260c2884d1358efc3e653.tar.gz
prosody-93d0d13fbb20af44330260c2884d1358efc3e653.zip
net.server: Backport client parts of SNI support from trunk (#409)
Partial backports of the following commits from trunk: 6c804b6b2ca2 net.http: Pass server name along for SNI (fixes #1408) 75d2874502c3 net.server_select: SNI support (#409) 9a905888b96c net.server_event: Add SNI support (#409) adc0672b700e net.server_epoll: Add support for SNI (#409) d4390c427a66 net.server: Handle server name (SNI) as extra argument
Diffstat (limited to 'net/http.lua')
-rw-r--r--net/http.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/http.lua b/net/http.lua
index ae9d2974..0768cdab 100644
--- a/net/http.lua
+++ b/net/http.lua
@@ -272,7 +272,7 @@ local function request(self, u, ex, callback)
sslctx = ex and ex.sslctx or self.options and self.options.sslctx;
end
- local http_service = basic_resolver.new(host, port_number);
+ local http_service = basic_resolver.new(host, port_number, "tcp", { servername = req.host });
connect(http_service, listener, { sslctx = sslctx }, req);
self.events.fire_event("request", { http = self, request = req, url = u });