Correct the "Out of memory" EVP tests
authorRichard Levitte <levitte@openssl.org>
Tue, 7 Sep 2021 05:27:01 +0000 (07:27 +0200)
committerRichard Levitte <levitte@openssl.org>
Tue, 7 Sep 2021 08:55:04 +0000 (10:55 +0200)
commit437d4202212daae86b66ef776706d2e1a27a7953
tree35c03bf343b657701b55ac58ca19d1b2d0b372ef
parent7364545e0734ad25e08d7d5ad0e2c9dac85d2d0d
Correct the "Out of memory" EVP tests

This affects test/recipes/30-test_evp_data/evpkdf_scrypt.txt and
test/recipes/30-test_evp_data/evppkey_kdf_scrypt.txt, where the "Out
of memory" stanza weren't up to the task, as they didn't hit the
default scrypt memory limit like they did in OpenSSL 1.1.1.

We solve this by setting the |n| value to the next power of two, and
correcting the expected result.

Fixes #16519

Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/16521)
test/recipes/30-test_evp_data/evpkdf_scrypt.txt
test/recipes/30-test_evp_data/evppkey_kdf_scrypt.txt