Argon2 incorrect result and division by zero
NIIBE Yutaka
gniibe at fsij.org
Fri Apr 1 04:18:32 CEST 2022
Hello,
Thanks a lot for your test case. It's my mistake in the implementation.
Guido Vranken wrote:
> It seems that the 64 bytes are always correct but with output sizes larger
> than that, discrepancies occur.
>
> Additionally there is a division by zero on this line in argon2_init() if
> parallelism is set to 0:
>
> segment_length = memory_blocks / (parallelism * 4);
>
> it would be better to return an error in this case.
Two problems are fixed in master by the commit:
564739a58426d89db2f0c9334659949e503d2c59
And 1.10 branch by:
13b5454d2620701863f6e89221f5f4c98d2aba8e
--
More information about the Gcrypt-devel
mailing list