diff options
author | Pauli <ppzgs1@gmail.com> | 2024-08-12 11:08:09 +1000 |
---|---|---|
committer | Pauli <ppzgs1@gmail.com> | 2024-08-14 08:17:45 +1000 |
commit | 21bcae6561d73e629f11e19975f24283559d36c0 (patch) | |
tree | 8bf6186d82a25707e16841ffcdd11cd3de656df5 | |
parent | bd3b24c3af6cc19efd14c9cff2a91bb58ef34559 (diff) |
test: Improve coverage for the PBKDF2 unit tests
Fixes #25136
Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
(Merged from https://github.com/openssl/openssl/pull/25160)
-rw-r--r-- | test/recipes/30-test_evp_data/evpkdf_pbkdf2.txt | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/test/recipes/30-test_evp_data/evpkdf_pbkdf2.txt b/test/recipes/30-test_evp_data/evpkdf_pbkdf2.txt index 6aca869b77..e01b47fbaa 100644 --- a/test/recipes/30-test_evp_data/evpkdf_pbkdf2.txt +++ b/test/recipes/30-test_evp_data/evpkdf_pbkdf2.txt @@ -228,7 +228,7 @@ Reason = xof digests not allowed Title = FIPS indicator tests -# Test that the operation with unapproved parameters is rejected +# Test that operations with unapproved parameters are rejected FIPSversion = >=3.4.0 KDF = PBKDF2 Ctrl.pass = pass:password @@ -238,7 +238,7 @@ Ctrl.digest = digest:sha1 Result = KDF_CTRL_ERROR Reason = invalid salt length -# Test that the operation with unapproved parameters is reported as unapproved +# Test that operations with unapproved parameters are reported as unapproved FIPSversion = >=3.4.0 KDF = PBKDF2 Unapproved = 1 @@ -259,3 +259,14 @@ Ctrl.salt = salt:saltSALTsaltSALTsaltSALTsaltSALTsalt Ctrl.iter = iter:4096 Ctrl.digest = digest:sha1 Output = 043c508e57c6427036fd2c6cd2a02ec7530a412c + +Title = Test that a too low iteration count raises an error + +Availablein = fips +KDF = PBKDF2 +Ctrl.pass = pass:password +Ctrl.salt = salt:saltydaysarethebest +Ctrl.iter = iter:10 +Ctrl.digest = digest:sha1 +Result = KDF_CTRL_ERROR +Reason = invalid iteration count |