mod_tls: More use of config sections removed

This commit is contained in:
Kim Alvefur 2013-03-23 02:35:50 +01:00
parent 1acfdf5914
commit 16c7c4e78d

View file

@ -92,10 +92,10 @@ module:hook_stanza(xmlns_starttls, "proceed", function (session, stanza)
end);
function module.load()
local ssl_config = config.rawget(module.host, "core", "ssl");
local ssl_config = config.rawget(module.host, "ssl");
if not ssl_config then
local base_host = module.host:match("%.(.*)");
ssl_config = config.get(base_host, "core", "ssl");
ssl_config = config.get(base_host, "ssl");
end
host.ssl_ctx = create_context(host.host, "client", ssl_config); -- for outgoing connections
host.ssl_ctx_in = create_context(host.host, "server", ssl_config); -- for incoming connections