test: add error reasons to HKDF tests

Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
Reviewed-by: Tom Cosgrove <tom.cosgrove@arm.com>
(Merged from https://github.com/openssl/openssl/pull/25135)
This commit is contained in:
Pauli 2024-08-08 13:35:17 +10:00
parent 77915ae8eb
commit 8c24acda18
2 changed files with 4 additions and 0 deletions

View File

@ -232,6 +232,7 @@ Ctrl.IKM = hexkey:0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b
Ctrl.salt = hexsalt:000102030405060708090a0b0c
Ctrl.info = hexinfo:f0f1f2f3f4f5f6f7f8f9
Result = KDF_CTRL_ERROR
Reason = xof digests not allowed
Title = FIPS indicator tests
@ -243,6 +244,7 @@ Ctrl.IKM = hexkey:0b0b0b0b0b0b0b0b0b0b0b
Ctrl.salt = hexsalt:000102030405060708090a0b0c
Ctrl.info = hexinfo:f0f1f2f3f4f5f6f7f8f9
Result = KDF_CTRL_ERROR
Reason = invalid key length
# Test that the key whose length is shorter than 112 bits is reported as
# unapproved

View File

@ -204,6 +204,7 @@ Ctrl.IKM = hexkey:0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b
Ctrl.salt = hexsalt:000102030405060708090a0b0c
Ctrl.info = hexinfo:f0f1f2f3f4f5f6f7f8f9
Result = PKEY_CTRL_ERROR
Reason = xof digests not allowed
Title = FIPS indicator tests
@ -215,6 +216,7 @@ Ctrl.IKM = hexkey:0b0b0b0b0b0b0b0b0b0b0b
Ctrl.salt = hexsalt:000102030405060708090a0b0c
Ctrl.info = hexinfo:f0f1f2f3f4f5f6f7f8f9
Result = PKEY_CTRL_ERROR
Reason = invalid key length
# Test that the key whose length is shorter than 112 bits is reported as
# unapproved