From 7cbe20b8b8d25299b2222b43c6e7885ef38cf6a4 Mon Sep 17 00:00:00 2001 From: olszomal Date: Mon, 30 Sep 2024 12:29:30 +0200 Subject: [PATCH] Workaround for openssl-3.2.0 and 3.2.1 --- src/eng_front.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/eng_front.c b/src/eng_front.c index fd6940fc..748df049 100644 --- a/src/eng_front.c +++ b/src/eng_front.c @@ -190,6 +190,11 @@ static EVP_PKEY *load_privkey(ENGINE *engine, const char *s_key_id, if (!ctx) return 0; bind_helper_methods(engine); + if (OpenSSL_version_num() == 0x30200000L || OpenSSL_version_num() == 0x30200010L) { + printf("Workaround for %s enabled\n", + OpenSSL_version(OPENSSL_VERSION)); + ENGINE_set_default_string(engine, "PKEY_CRYPTO"); + } pkey = ctx_load_privkey(ctx, s_key_id, ui_method, callback_data); #ifdef EVP_F_EVP_PKEY_SET1_ENGINE /* EVP_PKEY_set1_engine() is required for OpenSSL 1.1.x,