aboutsummaryrefslogtreecommitdiffstats
path: root/src/tests/test_ffi.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/tests/test_ffi.cpp')
-rw-r--r--src/tests/test_ffi.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/tests/test_ffi.cpp b/src/tests/test_ffi.cpp
index ce9dc94d5..2e59faec2 100644
--- a/src/tests/test_ffi.cpp
+++ b/src/tests/test_ffi.cpp
@@ -1511,9 +1511,15 @@ class FFI_Unit_Tests final : public Test
const std::string pbe_hash = "SHA-512";
#endif
+#if defined(BOTAN_HAS_GCM)
+ const std::string pbe_cipher = "AES-256/GCM";
+#else
+ const std::string pbe_cipher = "AES-256/CBC";
+#endif
+
TEST_FFI_OK(botan_privkey_export_encrypted_pbkdf_msec,
(priv, privkey.data(), &privkey_len, rng, "password",
- pbkdf_msec, &pbkdf_iters_out, "AES-256/GCM", pbe_hash.c_str(), 0));
+ pbkdf_msec, &pbkdf_iters_out, pbe_cipher.c_str(), pbe_hash.c_str(), 0));
if(pbe_hash == "Scrypt")
{