aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAlexander Bluhm <[email protected]>2018-11-08 11:00:47 -0700
committerAlexander Bluhm <[email protected]>2018-11-08 11:00:47 -0700
commite2e9f84b4b7f18e4b205f9f05e6e80b144c728d6 (patch)
tree8993e90d29c370b06c5774c94e5c27da7cd64d62 /src
parent8de311177ff7b3ad77afc4b0614b424a47205f31 (diff)
Run RSA blinding tests only with base provider
Only the base provider uses blinding for RSA. So the test should run exclusively for this provider. Also use base provider explicitly.
Diffstat (limited to 'src')
-rw-r--r--src/tests/test_rsa.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/tests/test_rsa.cpp b/src/tests/test_rsa.cpp
index 3688367d2..3ac5d4733 100644
--- a/src/tests/test_rsa.cpp
+++ b/src/tests/test_rsa.cpp
@@ -223,6 +223,13 @@ class RSA_Blinding_Tests final : public Test
{
Test::Result result("RSA blinding");
+ /* This test makes only sense with the base provider, else skip it. */
+ if (provider_filter({"base"}).empty())
+ {
+ result.note_missing("base provider");
+ return std::vector<Test::Result> {result};
+ }
+
#if defined(BOTAN_HAS_EMSA_RAW) || defined(BOTAN_HAS_EME_RAW)
Botan::RSA_PrivateKey rsa(Test::rng(), 1024);
Botan::Null_RNG null_rng;
@@ -239,7 +246,7 @@ class RSA_Blinding_Tests final : public Test
*/
Botan::PK_Signer signer(rsa, Test::rng(), "Raw", Botan::IEEE_1363, "base"); // don't try this at home
- Botan::PK_Verifier verifier(rsa, "Raw");
+ Botan::PK_Verifier verifier(rsa, "Raw", Botan::IEEE_1363, "base");
for(size_t i = 1; i <= BOTAN_BLINDING_REINIT_INTERVAL * 6; ++i)
{
@@ -266,7 +273,7 @@ class RSA_Blinding_Tests final : public Test
* are used as an additional test on the blinders.
*/
- Botan::PK_Encryptor_EME encryptor(rsa, Test::rng(), "Raw"); // don't try this at home
+ Botan::PK_Encryptor_EME encryptor(rsa, Test::rng(), "Raw", "base"); // don't try this at home
/*
Test blinding reinit interval