1
1
mirror of https://github.com/BLAKE2/BLAKE2 synced 2024-11-22 02:31:57 +01:00

blake2xs: fix key length check

This does not result in a buffer overflow, because luckily `BLAKE2B_KEYBYTES == BLAKE2S_BLOCKBYTES`.
This commit is contained in:
Samuel Neves 2023-02-07 16:12:58 +00:00 committed by GitHub
parent 54f4faa4c1
commit fb4b09b495
Signed by: GitHub
GPG Key ID: 4AEE18F83AFDEB23

@ -33,7 +33,7 @@ int blake2xs_init_key( blake2xs_state *S, const size_t outlen, const void *key,
return -1;
}
if (NULL != key && keylen > BLAKE2B_KEYBYTES) {
if (NULL != key && keylen > BLAKE2S_KEYBYTES) {
return -1;
}