Path: blob/main/crypto/openssl/include/internal/param_build_set.h
34879 views
/*1* Copyright 2020-2022 The OpenSSL Project Authors. All Rights Reserved.2*3* Licensed under the Apache License 2.0 (the "License"). You may not use4* this file except in compliance with the License. You can obtain a copy5* in the file LICENSE in the source distribution or at6* https://www.openssl.org/source/license.html7*/89#ifndef OSSL_INTERNAL_PARAM_BUILD_SET_H10# define OSSL_INTERNAL_PARAM_BUILD_SET_H11# pragma once1213# include <openssl/safestack.h>14# include <openssl/param_build.h>15# include "internal/cryptlib.h"1617typedef union {18OSSL_UNION_ALIGN;19} OSSL_PARAM_ALIGNED_BLOCK;2021# define OSSL_PARAM_ALIGN_SIZE sizeof(OSSL_PARAM_ALIGNED_BLOCK)2223size_t ossl_param_bytes_to_blocks(size_t bytes);24void ossl_param_set_secure_block(OSSL_PARAM *last, void *secure_buffer,25size_t secure_buffer_sz);2627int ossl_param_build_set_int(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,28const char *key, int num);29int ossl_param_build_set_long(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,30const char *key, long num);31int ossl_param_build_set_utf8_string(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,32const char *key, const char *buf);33int ossl_param_build_set_octet_string(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,34const char *key,35const unsigned char *data,36size_t data_len);37int ossl_param_build_set_bn(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,38const char *key, const BIGNUM *bn);39int ossl_param_build_set_bn_pad(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,40const char *key, const BIGNUM *bn, size_t sz);41int ossl_param_build_set_signed_bn(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,42const char *key, const BIGNUM *bn);43int ossl_param_build_set_signed_bn_pad(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,44const char *key, const BIGNUM *bn,45size_t sz);46int ossl_param_build_set_multi_key_bn(OSSL_PARAM_BLD *bld, OSSL_PARAM *p,47const char *names[],48STACK_OF(BIGNUM_const) *stk);4950#endif /* OSSL_INTERNAL_PARAM_BUILD_SET_H */515253