blob: e0bcbcb9f94e3ee3975371a126c539d24e62586f [file] [log] [blame]
Richard Levittec41f3ae2019-03-17 18:06:59 +01001/*
Matt Caswell3c2bdd72021-04-08 13:04:41 +01002 * Copyright 2019-2021 The OpenSSL Project Authors. All Rights Reserved.
Richard Levittec41f3ae2019-03-17 18:06:59 +01003 *
4 * Licensed under the Apache License 2.0 (the "License"). You may not use
5 * this file except in compliance with the License. You can obtain a copy
6 * in the file LICENSE in the source distribution or at
7 * https://www.openssl.org/source/license.html
8 */
9
10#include <openssl/core.h>
11
Matt Caswell352d4822021-06-18 15:56:54 +010012typedef struct {
13 char *name;
14 char *value;
15} INFOPAIR;
16DEFINE_STACK_OF(INFOPAIR)
17
Matt Caswellb7248962021-06-21 15:59:41 +010018typedef struct {
Matt Caswell1d742032021-06-18 12:28:40 +010019 char *name;
Matt Caswell352d4822021-06-18 15:56:54 +010020 char *path;
Richard Levittec41f3ae2019-03-17 18:06:59 +010021 OSSL_provider_init_fn *init;
Matt Caswell352d4822021-06-18 15:56:54 +010022 STACK_OF(INFOPAIR) *parameters;
Richard Levittec41f3ae2019-03-17 18:06:59 +010023 unsigned int is_fallback:1;
Matt Caswellb7248962021-06-21 15:59:41 +010024} OSSL_PROVIDER_INFO;
Richard Levittec41f3ae2019-03-17 18:06:59 +010025
Matt Caswellb7248962021-06-21 15:59:41 +010026extern const OSSL_PROVIDER_INFO ossl_predefined_providers[];
Matt Caswell352d4822021-06-18 15:56:54 +010027
Matt Caswellb7248962021-06-21 15:59:41 +010028void ossl_provider_info_clear(OSSL_PROVIDER_INFO *info);
Matt Caswell352d4822021-06-18 15:56:54 +010029int ossl_provider_info_add_to_store(OSSL_LIB_CTX *libctx,
Matt Caswellb7248962021-06-21 15:59:41 +010030 OSSL_PROVIDER_INFO *entry);
31int ossl_provider_info_add_parameter(OSSL_PROVIDER_INFO *provinfo,
Matt Caswell352d4822021-06-18 15:56:54 +010032 const char *name,
33 const char *value);