util/sasl/scram.lua

changeset 3186
b308450740b0
parent 3123
0f21abc745ef
child 3188
d35b181a895a
equal deleted inserted replaced
3185:a31559c52842 3186:b308450740b0
103 local salted_password 103 local salted_password
104 if type(password) ~= "string" or type(salt) ~= "string" or type(iteration_count) ~= "number" then 104 if type(password) ~= "string" or type(salt) ~= "string" or type(iteration_count) ~= "number" then
105 return false, "inappropriate argument types" 105 return false, "inappropriate argument types"
106 end 106 end
107 if iteration_count < 4096 then 107 if iteration_count < 4096 then
108 log("warning", "Iteration count < 4096 which is the suggested minimum according to RFC 5802.") 108 log("warn", "Iteration count < 4096 which is the suggested minimum according to RFC 5802.")
109 end 109 end
110 110
111 return true, Hi(hmac_sha1, password, salt, iteration_count); 111 return true, Hi(hmac_sha1, password, salt, iteration_count);
112 end 112 end
113 113

mercurial