From aa0ed952869769dbf4c21e33566397f93f00e2e5 Mon Sep 17 00:00:00 2001 From: Jack Lloyd Date: Thu, 29 Mar 2018 16:59:14 -0400 Subject: Fix test when EMSA1 not compiled in [ci skip] --- src/tests/unit_x509.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/tests/unit_x509.cpp') diff --git a/src/tests/unit_x509.cpp b/src/tests/unit_x509.cpp index fe8d3fbd7..0cb88e577 100644 --- a/src/tests/unit_x509.cpp +++ b/src/tests/unit_x509.cpp @@ -550,6 +550,8 @@ Test::Result test_x509_authority_info_access_extension() test_result.test_eq("CA certificate signature algorithm (explicit)", Botan::OIDS::lookup(ca_cert_exp.signature_algorithm().oid),"RSA/EMSA4"); +#if defined(BOTAN_HAS_EMSA1) + // Try to set a padding scheme that is not supported for signing with the given key type opt.set_padding_scheme("EMSA1"); try @@ -563,6 +565,8 @@ Test::Result test_x509_authority_info_access_extension() sk->algo_name(), e.what(), "Invalid argument Encoding scheme with canonical name EMSA1 not supported for signature algorithm RSA"); } +#endif + test_result.test_eq("CA certificate signature algorithm (explicit)", Botan::OIDS::lookup(ca_cert_exp.signature_algorithm().oid),"RSA/EMSA4"); -- cgit v1.2.3