diff options
author | Matthew Wild <mwild1@gmail.com> | 2008-11-27 23:36:49 +0000 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2008-11-27 23:36:49 +0000 |
commit | efd0ef64bb4cbf51ecbd51280b4cf42d7f6e6ed8 (patch) | |
tree | fbb36c13b7526cb3f7d79d364e8b338c4fc81b34 /plugins/mod_saslauth.lua | |
parent | f588a0f5b0dd4c6b6d2c81a517594b50b45fc15b (diff) | |
parent | 631e249397fd7cd2a2c5a7cb4c1feba664a41b2e (diff) | |
download | prosody-efd0ef64bb4cbf51ecbd51280b4cf42d7f6e6ed8.tar.gz prosody-efd0ef64bb4cbf51ecbd51280b4cf42d7f6e6ed8.zip |
Merge from waqas
Diffstat (limited to 'plugins/mod_saslauth.lua')
-rw-r--r-- | plugins/mod_saslauth.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/mod_saslauth.lua b/plugins/mod_saslauth.lua index f549d0b9..616c5118 100644 --- a/plugins/mod_saslauth.lua +++ b/plugins/mod_saslauth.lua @@ -2,12 +2,13 @@ local st = require "util.stanza"; local sm_bind_resource = require "core.sessionmanager".bind_resource; local jid -local base64 = require "base64" +local base64 = require "util.encodings".base64; local usermanager_validate_credentials = require "core.usermanager".validate_credentials; local t_concat, t_insert = table.concat, table.insert; local tostring = tostring; local jid_split = require "util.jid".split +local md5 = require "util.hashes".md5; local log = require "util.logger".init("mod_saslauth"); @@ -50,7 +51,7 @@ local function password_callback(node, host, mechanism) if mechanism == "PLAIN" then return func, password; elseif mechanism == "DIGEST-MD5" then - return func, require "md5".sum(node..":"..host..":"..password); + return func, md5(node..":"..host..":"..password); end end return func, nil; |