aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_s2s
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2014-09-23 19:41:10 +0200
committerKim Alvefur <zash@zash.se>2014-09-23 19:41:10 +0200
commitfb8f6cc1fb1aef6cc62120fd3a31a997bd1ea34a (patch)
treeac1ee53ca52deeb2fe7e66d517c143bdd85ecedf /plugins/mod_s2s
parent092f833cfc25c279b24bb3bfc3ba59581c829473 (diff)
downloadprosody-fb8f6cc1fb1aef6cc62120fd3a31a997bd1ea34a.tar.gz
prosody-fb8f6cc1fb1aef6cc62120fd3a31a997bd1ea34a.zip
mod_s2s: Close s2s connections that can not proceed due to mod_dialback not being present
Diffstat (limited to 'plugins/mod_s2s')
-rw-r--r--plugins/mod_s2s/mod_s2s.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/mod_s2s/mod_s2s.lua b/plugins/mod_s2s/mod_s2s.lua
index 7ff921d9..a50387fb 100644
--- a/plugins/mod_s2s/mod_s2s.lua
+++ b/plugins/mod_s2s/mod_s2s.lua
@@ -154,6 +154,10 @@ function module.add_host(module)
-- so the stream is ready for stanzas. RFC 6120 Section 4.3
mark_connected(session);
return true;
+ elseif not session.dialback_verifying then
+ session.log("warn", "No SASL EXTERNAL offer and Dialback doesn't seem to be enabled, giving up");
+ session:close();
+ return false;
end
end, -1);
end