Software /
code /
prosody
Diff
plugins/mod_tls.lua @ 8133:102e1ec8bee1
Merge 0.10->trunk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 26 Apr 2017 11:55:27 +0200 |
parent | 8131:c8e3a0caa0a9 |
child | 9740:4b34687ede3f |
child | 9971:5b048ccd106f |
line wrap: on
line diff
--- a/plugins/mod_tls.lua Tue Apr 25 01:42:59 2017 +0200 +++ b/plugins/mod_tls.lua Wed Apr 26 11:55:27 2017 +0200 @@ -35,7 +35,8 @@ local ssl_ctx_c2s, ssl_ctx_s2sout, ssl_ctx_s2sin; local ssl_cfg_c2s, ssl_cfg_s2sout, ssl_cfg_s2sin; -do + +function module.load() local NULL, err = {}; local modhost = module.host; local parent = modhost:match("%.(.*)$"); @@ -61,6 +62,8 @@ if not ssl_ctx_s2sin then module:log("error", "Error creating contexts for s2sin: %s", err); end end +module:hook_global("config-reloaded", module.load); + local function can_do_tls(session) if not session.conn.starttls then if not session.secure then