Software /
code /
prosody
Comparison
util/startup.lua @ 12274:10447f940fec
util.startup: Enable DANE in http client library with use_dane
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 05 Feb 2022 01:36:10 +0100 |
parent | 12244:858d40d675ee |
child | 12294:81f147ddc4ab |
comparison
equal
deleted
inserted
replaced
12273:c0f49a4026f8 | 12274:10447f940fec |
---|---|
391 local http = require "net.http" | 391 local http = require "net.http" |
392 local config_ssl = config.get("*", "ssl") or {} | 392 local config_ssl = config.get("*", "ssl") or {} |
393 local https_client = config.get("*", "client_https_ssl") | 393 local https_client = config.get("*", "client_https_ssl") |
394 http.default.options.sslctx = require "core.certmanager".create_context("client_https port 0", "client", | 394 http.default.options.sslctx = require "core.certmanager".create_context("client_https port 0", "client", |
395 { capath = config_ssl.capath, cafile = config_ssl.cafile, verify = "peer", }, https_client); | 395 { capath = config_ssl.capath, cafile = config_ssl.cafile, verify = "peer", }, https_client); |
396 http.default.options.use_dane = config.get("*", "use_dane") | |
396 end | 397 end |
397 | 398 |
398 function startup.init_promise() | 399 function startup.init_promise() |
399 local promise = require "util.promise"; | 400 local promise = require "util.promise"; |
400 | 401 |