diff --git a/ejabberd_auth_http/src/scram2.erl b/ejabberd_auth_http/src/scram2.erl index 1c4ebd9..f344469 100644 --- a/ejabberd_auth_http/src/scram2.erl +++ b/ejabberd_auth_http/src/scram2.erl @@ -132,7 +132,7 @@ password_to_scram(Password) -> password_to_scram(#scram{} = Password, _) -> Password; password_to_scram(Password, IterationCount) -> - Salt = crypto:rand_bytes(?SALT_LENGTH), + Salt = p1_rand:bytes(?SALT_LENGTH), SaltedPassword = salted_password(Password, Salt, IterationCount), StoredKey = stored_key(scram2:client_key(SaltedPassword)), ServerKey = server_key(SaltedPassword),