Software /
code /
prosody
Comparison
plugins/mod_tls.lua @ 1912:126401a7159f
require_encryption deprecated, use c2s_require_encryption instead
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Mon, 05 Oct 2009 14:59:30 +0100 |
parent | 1911:bfe120db1ec4 |
child | 1913:da49a59dff7c |
comparison
equal
deleted
inserted
replaced
1911:bfe120db1ec4 | 1912:126401a7159f |
---|---|
9 local st = require "util.stanza"; | 9 local st = require "util.stanza"; |
10 | 10 |
11 local xmlns_stream = 'http://etherx.jabber.org/streams'; | 11 local xmlns_stream = 'http://etherx.jabber.org/streams'; |
12 local xmlns_starttls = 'urn:ietf:params:xml:ns:xmpp-tls'; | 12 local xmlns_starttls = 'urn:ietf:params:xml:ns:xmpp-tls'; |
13 | 13 |
14 local secure_auth_only = module:get_option("require_encryption"); | 14 local secure_auth_only = module:get_option("c2s_require_encryption") or module:get_option("require_encryption"); |
15 local secure_s2s_only = module:get_option("require_s2s_encryption"); | 15 local secure_s2s_only = module:get_option("require_s2s_encryption"); |
16 | 16 |
17 module:add_handler("c2s_unauthed", "starttls", xmlns_starttls, | 17 module:add_handler("c2s_unauthed", "starttls", xmlns_starttls, |
18 function (session, stanza) | 18 function (session, stanza) |
19 if session.conn.starttls then | 19 if session.conn.starttls then |