Software /
code /
prosody
Comparison
plugins/mod_saslauth.lua @ 8509:e1d274001855
Backed out changeset 89c42aff8510: The problem in ejabberd has reportedly been resolved and this change causes more problems than it solves (fixes #1006)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 04 Feb 2018 01:13:27 +0100 |
parent | 8479:867679b0fb03 |
child | 8510:149e98f88680 |
comparison
equal
deleted
inserted
replaced
8508:47115b0ca133 | 8509:e1d274001855 |
---|---|
108 condition = condition .. ": " .. text; | 108 condition = condition .. ": " .. text; |
109 end | 109 end |
110 module:log("info", "SASL EXTERNAL with %s failed: %s", session.to_host, condition); | 110 module:log("info", "SASL EXTERNAL with %s failed: %s", session.to_host, condition); |
111 | 111 |
112 session.external_auth = "failed" | 112 session.external_auth = "failed" |
113 session:close(); | |
114 return true; | |
115 end, 500) | 113 end, 500) |
114 | |
115 module:hook_stanza(xmlns_sasl, "failure", function (session, stanza) | |
116 -- TODO: Dialback wasn't loaded. Do something useful. | |
117 end, 90) | |
116 | 118 |
117 module:hook_tag("http://etherx.jabber.org/streams", "features", function (session, stanza) | 119 module:hook_tag("http://etherx.jabber.org/streams", "features", function (session, stanza) |
118 if session.type ~= "s2sout_unauthed" or not session.secure then return; end | 120 if session.type ~= "s2sout_unauthed" or not session.secure then return; end |
119 | 121 |
120 local mechanisms = stanza:get_child("mechanisms", xmlns_sasl) | 122 local mechanisms = stanza:get_child("mechanisms", xmlns_sasl) |