Automated merge with http://prosody.im/source/hg
authorTobias Markmann <tm@ayena.de>
Sun, 06 Sep 2009 22:08:05 +0200
changeset 1759 4a280effc975
parent 1733 d55ee6c66910 (current diff)
parent 1758 5acbf4318715 (diff)
child 1760 0372bf35dcb3
Automated merge with http://prosody.im/source/hg
--- a/plugins/mod_saslauth.lua	Sat Sep 05 23:01:06 2009 +0100
+++ b/plugins/mod_saslauth.lua	Sun Sep 06 22:08:05 2009 +0200
@@ -84,7 +84,11 @@
 	elseif mechanism == "DIGEST-MD5" then
 		function func(x) return x; end
 		local node, domain, realm, decoder = ...;
-		local password = usermanager_get_password(node, domain);
+		local prepped_node = nodeprep(node);
+		if not prepped_node then
+			return func, nil;
+		end
+		local password = usermanager_get_password(prepped_node, domain);
 		if password then
 			if decoder then
 				node, realm, password = decoder(node), decoder(realm), decoder(password);