API参考
载入中...
搜索中...
未找到
crypt_sm_provider.h
1/*
2 * This file is part of the openHiTLS project.
3 *
4 * openHiTLS is licensed under the Mulan PSL v2.
5 * You can use this software according to the terms and conditions of the Mulan PSL v2.
6 * You may obtain a copy of Mulan PSL v2 at:
7 *
8 * http://license.coscl.org.cn/MulanPSL2
9 *
10 * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
11 * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
12 * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
13 * See the Mulan PSL v2 for more details.
14 */
15
21
22#ifndef CRYPT_EAL_SM_PROVIDER_H
23#define CRYPT_EAL_SM_PROVIDER_H
24
25#ifdef HITLS_CRYPTO_CMVP_SM
26
27#include <stdint.h>
28#include "crypt_eal_entropy.h"
29#include "crypt_eal_implprovider.h"
30#include "crypt_eal_cmvp.h"
31
32#ifdef __cplusplus
33extern "C" {
34#endif /* __cplusplus */
35
36#define CRYPT_EAL_SM_ATTR "provider=sm"
37
38typedef struct EalSmProvCtx {
39 void *libCtx;
40 void *mgrCtx;
41 CRYPT_EAL_Es *es;
42 CRYPT_EAL_SeedPoolCtx *pool;
43} CRYPT_EAL_SmProvCtx;
44
45int32_t CRYPT_EAL_ProviderInit(CRYPT_EAL_ProvMgrCtx *mgrCtx, BSL_Param *param, CRYPT_EAL_Func *capFuncs,
46 CRYPT_EAL_Func **outFuncs, void **provCtx);
47
48#ifdef __cplusplus
49}
50#endif /* __cplusplus */
51
52#endif /* HITLS_CRYPTO_CMVP_SM */
53#endif /* CRYPT_EAL_SM_PROVIDER_H */
定义 crypt_types.h:952