summaryrefslogtreecommitdiffstats
path: root/crypto/engine
diff options
context:
space:
mode:
authorNeil Horman <nhorman@openssl.org>2024-06-06 14:38:43 -0400
committerNeil Horman <nhorman@openssl.org>2024-07-09 04:01:44 -0400
commite6c77f26855661ec4bfe0a91fcf1c718ac48967f (patch)
treee478126a7506d7037540135ab15135f9b0064141 /crypto/engine
parentdd2b22d88c9c974f4ca6bce2550f89ac7fb76839 (diff)
convert users of build time defaults to use new defaults api
Now that we can query for install time registry keys on windows, convert users of these macros to use the api instead Add a unit test to validate the functionality of our reg key lookups Add a test to check to make sure our registry key lookups work. note this test only runs on windows (clearly), but also only if the registry keys are set via an installer or some other manual process (to be done in the CI workflow) Reviewed-by: Tomas Mraz <tomas@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/24450)
Diffstat (limited to 'crypto/engine')
-rw-r--r--crypto/engine/eng_list.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/crypto/engine/eng_list.c b/crypto/engine/eng_list.c
index eafca3ec49..b46403e556 100644
--- a/crypto/engine/eng_list.c
+++ b/crypto/engine/eng_list.c
@@ -408,7 +408,7 @@ static void engine_cpy(ENGINE *dest, const ENGINE *src)
ENGINE *ENGINE_by_id(const char *id)
{
ENGINE *iterator;
- char *load_dir = NULL;
+ const char *load_dir = NULL;
if (id == NULL) {
ERR_raise(ERR_LIB_ENGINE, ERR_R_PASSED_NULL_PARAMETER);
return NULL;
@@ -459,7 +459,7 @@ ENGINE *ENGINE_by_id(const char *id)
*/
if (strcmp(id, "dynamic")) {
if ((load_dir = ossl_safe_getenv("OPENSSL_ENGINES")) == NULL)
- load_dir = ENGINESDIR;
+ load_dir = ossl_get_enginesdir();
iterator = ENGINE_by_id("dynamic");
if (!iterator || !ENGINE_ctrl_cmd_string(iterator, "ID", id, 0) ||
!ENGINE_ctrl_cmd_string(iterator, "DIR_LOAD", "2", 0) ||