aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests/test_pubkey.cpp
diff options
context:
space:
mode:
authorMatthias Gierlings <[email protected]>2016-12-01 21:03:29 +0100
committerMatthias Gierlings <[email protected]>2016-12-01 21:13:50 +0100
commitfa6f766baa2f6a04d4d31bbec262c5e5dc11f8e4 (patch)
treea541c093daf2f8449173bb4a6633aa89b6a59174 /src/tests/test_pubkey.cpp
parentf85cbb9fe7896dd078da539e4b5f1553be10bebc (diff)
Updates module policy, fixes test suite errors
- Moves SHAKE to prohibited algorithms - Catches an error during XMSS private key generation when SHAKE is disabled. This should not be reported as error by the test bench since [SHAKE is optional in XMSS](https://tools.ietf.org/html/draft-irtf-cfrg-xmss-hash-based-signatures-07#section-5)
Diffstat (limited to 'src/tests/test_pubkey.cpp')
-rw-r--r--src/tests/test_pubkey.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/tests/test_pubkey.cpp b/src/tests/test_pubkey.cpp
index c2c1bb256..293756db9 100644
--- a/src/tests/test_pubkey.cpp
+++ b/src/tests/test_pubkey.cpp
@@ -88,7 +88,17 @@ PK_Signature_Generation_Test::run_one_test(const std::string&, const VarMap& var
Test::Result result(algo_name() + "/" + padding + " signature generation");
- std::unique_ptr<Botan::Private_Key> privkey = load_private_key(vars);
+ std::unique_ptr<Botan::Private_Key> privkey;
+ try
+ {
+ privkey = load_private_key(vars);
+ }
+ catch(Botan::Lookup_Error& e)
+ {
+ result.note_missing(e.what());
+ return result;
+ }
+
std::unique_ptr<Botan::Public_Key> pubkey(Botan::X509::load_key(Botan::X509::BER_encode(*privkey)));
std::vector<std::unique_ptr<Botan::PK_Verifier>> verifiers;