Merge pull request #7848 from miyazakh/fips_wcPBKDF2ex

Check klen in byte in wc_PBKDF2_ex
This commit is contained in:
Daniel Pouzzner
2024-08-09 14:49:53 -05:00
committed by GitHub

View File

@@ -218,7 +218,7 @@ int wc_PBKDF2_ex(byte* output, const byte* passwd, int pLen, const byte* salt,
* length", ensure the returned bits for the derived master key are at a
* minimum 14-bytes or 112-bits after stretching and strengthening
* (iterations) */
if (kLen < HMAC_FIPS_MIN_KEY/8)
if (kLen < HMAC_FIPS_MIN_KEY)
return BAD_LENGTH_E;
#endif