API参考
载入中...
搜索中...
未找到
eal_rand_local.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
16#ifndef EAL_RAND_LOCAL_H
17#define EAL_RAND_LOCAL_H
18
19#include "hitls_build.h"
20#if (defined(HITLS_CRYPTO_EAL) || defined(HITLS_CRYPTO_PROVIDER)) && \
21 (defined(HITLS_CRYPTO_DRBG) || defined(HITLS_CRYPTO_MULTI_DRBG))
22#include <stdint.h>
23
24#include "crypt_drbg.h"
25#include "crypt_utils.h"
26#include "bsl_params.h"
27
28#ifdef __cplusplus
29extern "C" {
30#endif // __cplusplus
31
32int32_t DRBG_InstantiateWrapper(DRBG_Ctx *ctx, const uint8_t *person, uint32_t persLen, const BSL_Param *params);
33
34int32_t DRBG_ReSeedWrapper(DRBG_Ctx *ctx, const uint8_t *adin, uint32_t adinLen, const BSL_Param *params);
35
36int32_t DRBG_GenerateBytesWrapper(DRBG_Ctx *ctx, uint8_t *out, uint32_t outLen,
37 const uint8_t *adin, uint32_t adinLen, const BSL_Param *params);
38
39#ifdef __cplusplus
40}
41#endif // __cplusplus
42
43#endif
44
45#endif