Skip to content

Commit 6243890

Browse files
committed
Skip the "lib" prefix when guessing engine ID
Fix #436
1 parent 829e770 commit 6243890

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

osslsigncode.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4141,9 +4141,11 @@ static ENGINE *engine_dynamic(GLOBAL_OPTIONS *options)
41414141
ptr = strrchr(options->p11engine, '/');
41424142
if (!ptr) /* no slash -> try backslash */
41434143
ptr = strrchr(options->p11engine, '\\');
4144-
if (ptr) /* directory separator found */
4144+
if (ptr) { /* directory separator found */
41454145
ptr++; /* skip it */
4146-
else /* directory separator not found */
4146+
if (!strncmp(ptr, "lib", 3))
4147+
ptr += 3; /* skip the "lib" prefix */
4148+
} else /* directory separator not found */
41474149
ptr = options->p11engine;
41484150
id = OPENSSL_strdup(ptr);
41494151
ptr = strchr(id, '.');

0 commit comments

Comments
 (0)