Prosody IM trunk


changeset 1bb1e16f24b0

mod_s2s: Close with a stream error in case neither SASL or Dialback are available This both tells the remote server and users who sent any queued stanzas why it failed.

author
Kim Alvefur
date
parents
children
files

1 files changed, 4 insertions(+), 1 deletions(-)

↓ Download patch

--- a/plugins/mod_s2s/mod_s2s.lua	Sun Oct 06 19:35:35 2019 +0200
+++ b/plugins/mod_s2s/mod_s2s.lua	Sun Oct 06 21:14:53 2019 +0200
@@ -184,7 +184,10 @@
 			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();
+			session:close({
+					condition = "unsupported-feature",
+					text = "No viable authentication method offered",
+				});
 			return false;
 		end
 	end, -1);