From e9fb0eb1130a8efacab3add17f524197a9044a88 Mon Sep 17 00:00:00 2001 From: Dimitri Staessens Date: Mon, 26 Jan 2026 17:48:38 +0100 Subject: lib: Fix crypt test and secure memory initialization The crypt_test had a HAVE_OPENSSL guard missing and was trying to execute tests that required OpenSSL without it being installed. The SECMEM values need to be set by CMake without OpenSSL installed. Signed-off-by: Dimitri Staessens Signed-off-by: Sander Vrijders --- src/lib/tests/crypt_test.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/lib/tests/crypt_test.c b/src/lib/tests/crypt_test.c index e1232b8c..e250ad2a 100644 --- a/src/lib/tests/crypt_test.c +++ b/src/lib/tests/crypt_test.c @@ -444,11 +444,16 @@ int crypt_test(int argc, ret |= test_crypt_create_destroy(); ret |= test_encrypt_decrypt_all(); - ret |= test_key_rotation(); - ret |= test_key_phase_bit(); #ifdef HAVE_OPENSSL ret |= test_cipher_nid_values(); ret |= test_md_nid_values(); + ret |= test_key_rotation(); + ret |= test_key_phase_bit(); +#else + (void) test_key_rotation; + (void) test_key_phase_bit; + + return TEST_RC_SKIP; #endif return ret; } -- cgit v1.2.3