summaryrefslogtreecommitdiffstats
path: root/providers/nullprov.c
diff options
context:
space:
mode:
Diffstat (limited to 'providers/nullprov.c')
-rw-r--r--providers/nullprov.c36
1 files changed, 3 insertions, 33 deletions
diff --git a/providers/nullprov.c b/providers/nullprov.c
index a1a2681173..945ec2fbb6 100644
--- a/providers/nullprov.c
+++ b/providers/nullprov.c
@@ -17,10 +17,6 @@
OSSL_provider_init_fn ossl_null_provider_init;
-/* Functions provided by the core */
-static OSSL_core_gettable_params_fn *c_gettable_params = NULL;
-static OSSL_core_get_params_fn *c_get_params = NULL;
-
/* Parameters we provide to the core */
static const OSSL_ITEM null_param_types[] = {
{ OSSL_PARAM_UTF8_PTR, OSSL_PROV_PARAM_NAME },
@@ -67,40 +63,14 @@ static const OSSL_DISPATCH null_dispatch_table[] = {
{ 0, NULL }
};
-int ossl_null_provider_init(const OSSL_PROVIDER *provider,
+int ossl_null_provider_init(const OSSL_CORE_HANDLE *handle,
const OSSL_DISPATCH *in,
const OSSL_DISPATCH **out,
void **provctx)
{
- OSSL_core_get_library_context_fn *c_get_libctx = NULL;
-
- for (; in->function_id != 0; in++) {
- switch (in->function_id) {
- case OSSL_FUNC_CORE_GETTABLE_PARAMS:
- c_gettable_params = OSSL_get_core_gettable_params(in);
- break;
- case OSSL_FUNC_CORE_GET_PARAMS:
- c_get_params = OSSL_get_core_get_params(in);
- break;
- case OSSL_FUNC_CORE_GET_LIBRARY_CONTEXT:
- c_get_libctx = OSSL_get_core_get_library_context(in);
- break;
- /* Just ignore anything we don't understand */
- default:
- break;
- }
- }
-
- if (c_get_libctx == NULL)
- return 0;
-
*out = null_dispatch_table;
- /*
- * We want to make sure that all calls from this provider that requires
- * a library context use the same context as the one used to call our
- * functions. We do that by passing it along as the provider context.
- */
- *provctx = c_get_libctx(provider);
+ /* Could be anything - we don't use it */
+ *provctx = (void *)handle;
return 1;
}