VirtualBox

source: vbox/trunk/src/libs/openssl-3.0.7/include/internal/provider.h@ 99507

最後變更 在這個檔案從99507是 97984,由 vboxsync 提交於 2 年 前

libs/openssl-3.0.7: Shut up pragma once warnings for internal headers. Added sed script for doing that. bugref:10317

檔案大小: 5.0 KB
 
1/*
2 * Copyright 2019-2022 The OpenSSL Project Authors. All Rights Reserved.
3 *
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#ifndef OSSL_INTERNAL_PROVIDER_H
11# define OSSL_INTERNAL_PROVIDER_H
12# ifndef RT_WITHOUT_PRAGMA_ONCE /* VBOX */
13# pragma once
14# endif /* VBOX */
15
16# include <openssl/core.h>
17# include <openssl/core_dispatch.h>
18# include "internal/dso.h"
19# include "internal/symhacks.h"
20
21# ifdef __cplusplus
22extern "C" {
23# endif
24
25/*
26 * namespaces:
27 *
28 * ossl_provider_ Provider Object internal API
29 * OSSL_PROVIDER Provider Object
30 */
31
32/* Provider Object finder, constructor and destructor */
33OSSL_PROVIDER *ossl_provider_find(OSSL_LIB_CTX *libctx, const char *name,
34 int noconfig);
35OSSL_PROVIDER *ossl_provider_new(OSSL_LIB_CTX *libctx, const char *name,
36 OSSL_provider_init_fn *init_function,
37 int noconfig);
38int ossl_provider_up_ref(OSSL_PROVIDER *prov);
39void ossl_provider_free(OSSL_PROVIDER *prov);
40
41/* Setters */
42int ossl_provider_set_fallback(OSSL_PROVIDER *prov);
43int ossl_provider_set_module_path(OSSL_PROVIDER *prov, const char *module_path);
44int ossl_provider_add_parameter(OSSL_PROVIDER *prov, const char *name,
45 const char *value);
46
47int ossl_provider_is_child(const OSSL_PROVIDER *prov);
48int ossl_provider_set_child(OSSL_PROVIDER *prov, const OSSL_CORE_HANDLE *handle);
49const OSSL_CORE_HANDLE *ossl_provider_get_parent(OSSL_PROVIDER *prov);
50int ossl_provider_up_ref_parent(OSSL_PROVIDER *prov, int activate);
51int ossl_provider_free_parent(OSSL_PROVIDER *prov, int deactivate);
52int ossl_provider_default_props_update(OSSL_LIB_CTX *libctx, const char *props);
53
54/* Disable fallback loading */
55int ossl_provider_disable_fallback_loading(OSSL_LIB_CTX *libctx);
56
57/*
58 * Activate the Provider
59 * If the Provider is a module, the module will be loaded
60 */
61int ossl_provider_activate(OSSL_PROVIDER *prov, int upcalls, int aschild);
62int ossl_provider_deactivate(OSSL_PROVIDER *prov, int removechildren);
63int ossl_provider_add_to_store(OSSL_PROVIDER *prov, OSSL_PROVIDER **actualprov,
64 int retain_fallbacks);
65
66/* Return pointer to the provider's context */
67void *ossl_provider_ctx(const OSSL_PROVIDER *prov);
68
69/* Iterate over all loaded providers */
70int ossl_provider_doall_activated(OSSL_LIB_CTX *,
71 int (*cb)(OSSL_PROVIDER *provider,
72 void *cbdata),
73 void *cbdata);
74
75/* Getters for other library functions */
76const char *ossl_provider_name(const OSSL_PROVIDER *prov);
77const DSO *ossl_provider_dso(const OSSL_PROVIDER *prov);
78const char *ossl_provider_module_name(const OSSL_PROVIDER *prov);
79const char *ossl_provider_module_path(const OSSL_PROVIDER *prov);
80void *ossl_provider_prov_ctx(const OSSL_PROVIDER *prov);
81const OSSL_DISPATCH *ossl_provider_get0_dispatch(const OSSL_PROVIDER *prov);
82OSSL_LIB_CTX *ossl_provider_libctx(const OSSL_PROVIDER *prov);
83
84/* Thin wrappers around calls to the provider */
85void ossl_provider_teardown(const OSSL_PROVIDER *prov);
86const OSSL_PARAM *ossl_provider_gettable_params(const OSSL_PROVIDER *prov);
87int ossl_provider_get_params(const OSSL_PROVIDER *prov, OSSL_PARAM params[]);
88int ossl_provider_get_capabilities(const OSSL_PROVIDER *prov,
89 const char *capability,
90 OSSL_CALLBACK *cb,
91 void *arg);
92int ossl_provider_self_test(const OSSL_PROVIDER *prov);
93const OSSL_ALGORITHM *ossl_provider_query_operation(const OSSL_PROVIDER *prov,
94 int operation_id,
95 int *no_cache);
96void ossl_provider_unquery_operation(const OSSL_PROVIDER *prov,
97 int operation_id,
98 const OSSL_ALGORITHM *algs);
99
100/*
101 * Cache of bits to see if we already added methods for an operation in
102 * the "permanent" method store.
103 * They should never be called for temporary method stores!
104 */
105int ossl_provider_set_operation_bit(OSSL_PROVIDER *provider, size_t bitnum);
106int ossl_provider_test_operation_bit(OSSL_PROVIDER *provider, size_t bitnum,
107 int *result);
108
109/* Configuration */
110void ossl_provider_add_conf_module(void);
111
112/* Child providers */
113int ossl_provider_init_as_child(OSSL_LIB_CTX *ctx,
114 const OSSL_CORE_HANDLE *handle,
115 const OSSL_DISPATCH *in);
116void ossl_provider_deinit_child(OSSL_LIB_CTX *ctx);
117
118# ifdef __cplusplus
119}
120# endif
121
122#endif
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette