From 10ffdda4209371dcd839d78081e1a65d2a8b67b0 Mon Sep 17 00:00:00 2001 From: Pauli Date: Tue, 2 Mar 2021 09:01:14 +1000 Subject: [PATCH] test: add params argument to key manager's gen_init call Reviewed-by: Shane Lontis (Merged from https://github.com/openssl/openssl/pull/14383) --- test/tls-provider.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/test/tls-provider.c b/test/tls-provider.c index 03e2ae1f0eb..20598041e08 100644 --- a/test/tls-provider.c +++ b/test/tls-provider.c @@ -317,7 +317,7 @@ static int xor_encapsulate(void *vpxorctx, } /* 1. Generate keypair */ - genctx = xor_gen_init(pxorctx->provctx, OSSL_KEYMGMT_SELECT_KEYPAIR); + genctx = xor_gen_init(pxorctx->provctx, OSSL_KEYMGMT_SELECT_KEYPAIR, NULL); if (genctx == NULL) goto end; ourkey = xor_gen(genctx, NULL, NULL); @@ -537,7 +537,8 @@ struct xor_gen_ctx { OSSL_LIB_CTX *libctx; }; -static void *xor_gen_init(void *provctx, int selection) +static void *xor_gen_init(void *provctx, int selection, + const OSSL_PARAM params[]) { struct xor_gen_ctx *gctx = NULL; @@ -551,6 +552,10 @@ static void *xor_gen_init(void *provctx, int selection) /* Our provctx is really just an OSSL_LIB_CTX */ gctx->libctx = (OSSL_LIB_CTX *)provctx; + if (!xor_gen_set_params(gctx, params)) { + OPENSSL_free(gctx); + return NULL; + } return gctx; } -- 2.47.3