Add hash to scramed password stored in mnesia by earlier version

This commit is contained in:
Paweł Chmielowski 2020-12-08 12:18:03 +01:00
parent 1dc0ecd1e9
commit e5cad9be65
1 changed files with 3 additions and 0 deletions

View File

@ -180,6 +180,9 @@ count_users(Server, _) ->
get_password(User, Server) ->
case mnesia:dirty_read(passwd, {User, Server}) of
[#passwd{password = {scram, SK, SEK, Salt, IC}}] ->
{cache, {ok, #scram{storedkey = SK, serverkey = SEK,
salt = Salt, hash = sha, iterationcount = IC}}};
[#passwd{password = Password}] ->
{cache, {ok, Password}};
_ ->