Software /
code /
prosody
Comparison
util/sasl/scram.lua @ 3123:0f21abc745ef
util.sasl.scram: Fix remaining - in profile name
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Mon, 24 May 2010 19:44:27 +0100 |
parent | 3122:579f17b9f948 |
child | 3124:21e60658767d |
child | 3194:b308450740b0 |
comparison
equal
deleted
inserted
replaced
3122:579f17b9f948 | 3123:0f21abc745ef |
---|---|
162 if not succ then | 162 if not succ then |
163 log("error", "Generating salted password failed. Reason: %s", self.state.salted_password); | 163 log("error", "Generating salted password failed. Reason: %s", self.state.salted_password); |
164 return "failure", "temporary-auth-failure"; | 164 return "failure", "temporary-auth-failure"; |
165 end | 165 end |
166 elseif self.profile["scram_"..hashprep(hash_name)] then | 166 elseif self.profile["scram_"..hashprep(hash_name)] then |
167 local salted_password, iteration_count, salt, state = self.profile["scram-"..hash_name](self.state.name, self.realm); | 167 local salted_password, iteration_count, salt, state = self.profile["scram_"..hashprep(hash_name)](self.state.name, self.realm); |
168 if state == nil then return "failure", "not-authorized" | 168 if state == nil then return "failure", "not-authorized" |
169 elseif state == false then return "failure", "account-disabled" end | 169 elseif state == false then return "failure", "account-disabled" end |
170 | 170 |
171 self.state.salted_password = salted_password; | 171 self.state.salted_password = salted_password; |
172 self.state.iteration_count = iteration_count; | 172 self.state.iteration_count = iteration_count; |