From 99064548e85d6eed9bfbe27fb5a4aee2d04836fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Chmielowski?= Date: Tue, 17 May 2022 12:23:12 +0200 Subject: [PATCH] Fix parsing of scram password from prosody Looks like parsed integer no longer are convered to floats on erlang side, so let's make check for them less restrictive. --- src/prosody2ejabberd.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/prosody2ejabberd.erl b/src/prosody2ejabberd.erl index 07b6427e7..df7dedc9b 100644 --- a/src/prosody2ejabberd.erl +++ b/src/prosody2ejabberd.erl @@ -130,7 +130,7 @@ eval_file(Path) -> maybe_get_scram_auth(Data) -> case proplists:get_value(<<"iteration_count">>, Data, no_ic) of - IC when is_float(IC) -> %% A float like 4096.0 is read + IC when is_number(IC) -> #scram{ storedkey = misc:hex_to_base64(proplists:get_value(<<"stored_key">>, Data, <<"">>)), serverkey = misc:hex_to_base64(proplists:get_value(<<"server_key">>, Data, <<"">>)),