Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add CAST for SP 800-56Cr2 One-Step function (#1803)
### Description of changes: Adds a cryptographic algorithm self test (CAST) for SP 800-56Cr2 OneStep function. Per the FIPS 140-3 I.G. Guidance Item: > if the module implements an approved KDA (SP 800-56C rev1 or rev2), the module shall perform at least one CAST covering a SP 800-56Crev1 Section 4 one-step KDF (if implemented) and another CAST covering a SP 800-56Crev1 Section 5 two-step KDF (if implemented), including at least one auxiliary function for each. For example, if a module implements both a two-step KDF using either the HMAC or AES-CMAC auxiliary function, and one-step KDF using either the hash or HMAC auxiliary function, then at least two CASTs are required: one for the two-step KDF (with either HMAC or AES-CMAC), and the other for the one-step KDF (with either the hash or HMAC). The implementations of the auxiliary functions used in the KDA CASTs do not require separate CASTs. In addition, the module shall self-test all underlying prerequisite algorithms used in the remaining SP 800-56C rev1 or rev2 schemes implemented in the module, if the same implementations of the underlying algorithms are not already self-tested either on their own or as part of other higher-level algorithm CASTs. I have interpreted this item as requiring us only needing to test either `SSKDF_digest` or `SSKDF_hmac` but aren't required to test both. ### Testing: The KAT used in this test case was sourced from `util/fipstools/acvp/acvptool/test/vectors/KDA-OneStep.bz2` and `util/fipstools/acvp/acvptool/test/expected/KDA-OneStep.bz2`. By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license and the ISC license.
- Loading branch information