]> git.ipfire.org Git - thirdparty/openssl.git/blob - providers/common/ciphers/cipher_local.h
Reorganize local header files
[thirdparty/openssl.git] / providers / common / ciphers / cipher_local.h
1 /*
2 * Copyright 2019 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 #include "internal/ciphers/ciphercommon.h"
11
12 #define CIPHER_DEFAULT_GETTABLE_CTX_PARAMS_START(name) \
13 static const OSSL_PARAM name##_known_gettable_ctx_params[] = { \
14 OSSL_PARAM_size_t(OSSL_CIPHER_PARAM_KEYLEN, NULL), \
15 OSSL_PARAM_size_t(OSSL_CIPHER_PARAM_IVLEN, NULL), \
16 OSSL_PARAM_uint(OSSL_CIPHER_PARAM_PADDING, NULL), \
17 OSSL_PARAM_uint(OSSL_CIPHER_PARAM_NUM, NULL), \
18 OSSL_PARAM_octet_string(OSSL_CIPHER_PARAM_IV, NULL, 0),
19
20 #define CIPHER_DEFAULT_GETTABLE_CTX_PARAMS_END(name) \
21 OSSL_PARAM_END \
22 }; \
23 const OSSL_PARAM * name##_gettable_ctx_params(void) \
24 { \
25 return name##_known_gettable_ctx_params; \
26 }
27
28 void padblock(unsigned char *buf, size_t *buflen, size_t blocksize);
29 int unpadblock(unsigned char *buf, size_t *buflen, size_t blocksize);