Import Wycheproof's size-specific RSA PKCS#1 verifying tests.

It's unclear to me whether the normal rsa_signature_test.txt file is
still needed with these, but I've left it in for now.

Change-Id: I6db9c9556820263c2b0bc37d144e6403b9a7a178
Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/39189
Reviewed-by: Adam Langley <agl@google.com>
This commit is contained in:
David Benjamin 2019-12-14 11:30:34 -05:00 committed by Adam Langley
parent 906bbef001
commit 55ed2a60d3
12 changed files with 13219 additions and 0 deletions

View File

@ -705,6 +705,25 @@ TEST(EVPTest, WycheproofEdDSA) {
}
TEST(EVPTest, WycheproofRSAPKCS1) {
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_2048_sha224_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_2048_sha256_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_2048_sha384_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_2048_sha512_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_3072_sha256_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_3072_sha384_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_3072_sha512_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_4096_sha384_test.txt");
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_4096_sha512_test.txt");
// TODO(davidben): Is this file redundant with the tests above?
RunWycheproofTest(
"third_party/wycheproof_testvectors/rsa_signature_test.txt");
}

View File

@ -101,6 +101,15 @@ set(
third_party/wycheproof_testvectors/rsa_pss_4096_sha256_mgf1_32_test.txt
third_party/wycheproof_testvectors/rsa_pss_4096_sha512_mgf1_32_test.txt
third_party/wycheproof_testvectors/rsa_pss_misc_test.txt
third_party/wycheproof_testvectors/rsa_signature_2048_sha224_test.txt
third_party/wycheproof_testvectors/rsa_signature_2048_sha256_test.txt
third_party/wycheproof_testvectors/rsa_signature_2048_sha384_test.txt
third_party/wycheproof_testvectors/rsa_signature_2048_sha512_test.txt
third_party/wycheproof_testvectors/rsa_signature_3072_sha256_test.txt
third_party/wycheproof_testvectors/rsa_signature_3072_sha384_test.txt
third_party/wycheproof_testvectors/rsa_signature_3072_sha512_test.txt
third_party/wycheproof_testvectors/rsa_signature_4096_sha384_test.txt
third_party/wycheproof_testvectors/rsa_signature_4096_sha512_test.txt
third_party/wycheproof_testvectors/rsa_signature_test.txt
third_party/wycheproof_testvectors/x25519_test.txt
third_party/wycheproof_testvectors/xchacha20_poly1305_test.txt

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -232,6 +232,15 @@ var defaultInputs = []string{
"rsa_pss_4096_sha256_mgf1_32_test.json",
"rsa_pss_4096_sha512_mgf1_32_test.json",
"rsa_pss_misc_test.json",
"rsa_signature_2048_sha224_test.json",
"rsa_signature_2048_sha256_test.json",
"rsa_signature_2048_sha384_test.json",
"rsa_signature_2048_sha512_test.json",
"rsa_signature_3072_sha256_test.json",
"rsa_signature_3072_sha384_test.json",
"rsa_signature_3072_sha512_test.json",
"rsa_signature_4096_sha384_test.json",
"rsa_signature_4096_sha512_test.json",
"rsa_signature_test.json",
"x25519_test.json",
"xchacha20_poly1305_test.json",