Automated merge with http://prosody.im/source/hg
authorTobias Markmann <tm@ayena.de>
Sun, 6 Sep 2009 20:08:05 +0000 (22:08 +0200)
committerTobias Markmann <tm@ayena.de>
Sun, 6 Sep 2009 20:08:05 +0000 (22:08 +0200)
plugins/mod_saslauth.lua

index da66717cf2e48a0e744709f4c60acfe749fe1d1a..6051bf9d76284afc59bafd3f104aec4a3a5959a6 100644 (file)
@@ -84,7 +84,11 @@ local function credentials_callback(mechanism, ...)
        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);