aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBadlop <badlop@process-one.net>2015-04-04 14:09:58 +0200
committerBadlop <badlop@process-one.net>2015-04-04 14:09:58 +0200
commit7d3b2cad268bd199ae2765cee8a9d4c12cd92c5f (patch)
tree7f1eb5d08432c8c3e8abc475f4ff9e4c3e92f8da
parentReplace undefined value with empty one (processone/ejabberd-contrib#92) (diff)
Replace crypto calls that will be removed in a future release
-rw-r--r--src/mod_admin_extra.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mod_admin_extra.erl b/src/mod_admin_extra.erl
index 043b6f3c1..0162a40c3 100644
--- a/src/mod_admin_extra.erl
+++ b/src/mod_admin_extra.erl
@@ -603,10 +603,10 @@ check_password_hash(User, Host, PasswordHash, HashMethod) ->
end.
get_md5(AccountPass) ->
lists:flatten([io_lib:format("~.16B", [X])
- || X <- binary_to_list(crypto:md5(AccountPass))]).
+ || X <- binary_to_list(erlang:md5(AccountPass))]).
get_sha(AccountPass) ->
lists:flatten([io_lib:format("~.16B", [X])
- || X <- binary_to_list(crypto:sha(AccountPass))]).
+ || X <- binary_to_list(p1_sha:sha1(AccountPass))]).
num_active_users(Host, Days) ->
list_last_activity(Host, true, Days).