# HG changeset patch # User Tobias Markmann # Date 1259431138 -3600 # Node ID e4c5d0d21ac723bcb1f1a36d1a748ff9f5b96dc1 # Parent c1a85068ca3689c740690752af422472358ca8c4 util.sasl.digest-md5: Fixing some variable access. diff -r c1a85068ca36 -r e4c5d0d21ac7 util/sasl/digest-md5.lua --- a/util/sasl/digest-md5.lua Sat Nov 28 17:40:49 2009 +0000 +++ b/util/sasl/digest-md5.lua Sat Nov 28 18:58:58 2009 +0100 @@ -166,13 +166,14 @@ --TODO maybe realm support self.username = response["username"]; + local Y, state; if self.profile.plain then local password, state = self.profile.plain(response["username"], self.realm) if state == nil then return "failure", "not-authorized" elseif state == false then return "failure", "account-disabled" end - local Y = md5(response["username"]..":"..response["realm"]..":"..password); + Y = md5(response["username"]..":"..response["realm"]..":"..password); elseif self.profile["digest-md5"] then - local Y, state = self.profile["digest-md5"](response["username"], self.realm, response["realm"], response["charset"]) + Y, state = self.profile["digest-md5"](response["username"], self.realm, response["realm"], response["charset"]) if state == nil then return "failure", "not-authorized" elseif state == false then return "failure", "account-disabled" end elseif self.profile["digest-md5-test"] then