Skip to content

Commit

Permalink
Workaround for openssl-3.2.0 and 3.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
olszomal committed Sep 13, 2024
1 parent 514a8be commit a4959d5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/eng_front.c
Original file line number Diff line number Diff line change
Expand Up @@ -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 OpenSSL-%s enabled\n",
OpenSSL_version(OPENSSL_VERSION_STRING));
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,
Expand Down

0 comments on commit a4959d5

Please sign in to comment.