From 1ba686ac651f26041dc8e9255b719c57e56a2f6f Mon Sep 17 00:00:00 2001 From: William Bo Yang Date: Tue, 10 Oct 2023 11:45:09 -0700 Subject: [PATCH] add support for RSA KeyGen AFT tests for FIPS186-5 (#1234) --- util/fipstools/acvp/acvptool/subprocess/rsa.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/util/fipstools/acvp/acvptool/subprocess/rsa.go b/util/fipstools/acvp/acvptool/subprocess/rsa.go index 2d5a46f119..4140c7f560 100644 --- a/util/fipstools/acvp/acvptool/subprocess/rsa.go +++ b/util/fipstools/acvp/acvptool/subprocess/rsa.go @@ -126,10 +126,9 @@ func processKeyGen(vectorSet []byte, m Transactable) (any, error) { var ret []rsaKeyGenTestGroupResponse for _, group := range parsed.Groups { - // GDT means "Generated data test", i.e. "please generate an RSA key". - const expectedType = "GDT" - if group.Type != expectedType { - return nil, fmt.Errorf("RSA KeyGen test group has type %q, but only generation tests (%q) are supported", group.Type, expectedType) + // We support both GDT and AFT tests, which are formatted the same and expect the same output. + if !(group.Type == "GDT" || group.Type == "AFT") { + return nil, fmt.Errorf("RSA KeyGen test group has type %q, but only GDT and AFT tests are supported", group.Type) } response := rsaKeyGenTestGroupResponse{