blob: 651f42d938eded1fde770a870769f6476cd54409 [file] [log] [blame]
Paul Bakker8123e9d2011-01-06 15:37:30 +00001/**
2 * \file cipher_wrap.h
3 *
4 * \brief Cipher wrappers.
5 *
6 * \author Adriaan de Jong <dejong@fox-it.com>
7 *
Paul Bakker530927b2015-02-13 14:24:10 +01008 * Copyright (C) 2006-2015, ARM Limited, All Rights Reserved
Paul Bakker8123e9d2011-01-06 15:37:30 +00009 *
Manuel Pégourié-Gonnarde12abf92015-01-28 17:13:45 +000010 * This file is part of mbed TLS (https://polarssl.org)
Paul Bakker8123e9d2011-01-06 15:37:30 +000011 *
12 * This program is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2 of the License, or
15 * (at your option) any later version.
16 *
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License along
23 * with this program; if not, write to the Free Software Foundation, Inc.,
24 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
25 */
Paul Bakkercce9d772011-11-18 14:26:47 +000026#ifndef POLARSSL_CIPHER_WRAP_H
27#define POLARSSL_CIPHER_WRAP_H
Paul Bakker8123e9d2011-01-06 15:37:30 +000028
Paul Bakker314052f2011-08-15 09:07:52 +000029#include "config.h"
30#include "cipher.h"
Paul Bakker8123e9d2011-01-06 15:37:30 +000031
Paul Bakker8123e9d2011-01-06 15:37:30 +000032#ifdef __cplusplus
33extern "C" {
34#endif
35
36#if defined(POLARSSL_AES_C)
37
38extern const cipher_info_t aes_128_cbc_info;
39extern const cipher_info_t aes_192_cbc_info;
40extern const cipher_info_t aes_256_cbc_info;
41
Paul Bakker343a8702011-06-09 14:27:58 +000042#if defined(POLARSSL_CIPHER_MODE_CFB)
43extern const cipher_info_t aes_128_cfb128_info;
44extern const cipher_info_t aes_192_cfb128_info;
45extern const cipher_info_t aes_256_cfb128_info;
46#endif /* POLARSSL_CIPHER_MODE_CFB */
47
48#if defined(POLARSSL_CIPHER_MODE_CTR)
49extern const cipher_info_t aes_128_ctr_info;
50extern const cipher_info_t aes_192_ctr_info;
51extern const cipher_info_t aes_256_ctr_info;
52#endif /* POLARSSL_CIPHER_MODE_CTR */
53
Paul Bakker8123e9d2011-01-06 15:37:30 +000054#endif /* defined(POLARSSL_AES_C) */
55
56#if defined(POLARSSL_CAMELLIA_C)
57
58extern const cipher_info_t camellia_128_cbc_info;
59extern const cipher_info_t camellia_192_cbc_info;
60extern const cipher_info_t camellia_256_cbc_info;
61
Paul Bakker343a8702011-06-09 14:27:58 +000062#if defined(POLARSSL_CIPHER_MODE_CFB)
63extern const cipher_info_t camellia_128_cfb128_info;
64extern const cipher_info_t camellia_192_cfb128_info;
65extern const cipher_info_t camellia_256_cfb128_info;
66#endif /* POLARSSL_CIPHER_MODE_CFB */
67
68#if defined(POLARSSL_CIPHER_MODE_CTR)
69extern const cipher_info_t camellia_128_ctr_info;
70extern const cipher_info_t camellia_192_ctr_info;
71extern const cipher_info_t camellia_256_ctr_info;
72#endif /* POLARSSL_CIPHER_MODE_CTR */
73
Paul Bakker8123e9d2011-01-06 15:37:30 +000074#endif /* defined(POLARSSL_CAMELLIA_C) */
75
76#if defined(POLARSSL_DES_C)
77
78extern const cipher_info_t des_cbc_info;
79extern const cipher_info_t des_ede_cbc_info;
80extern const cipher_info_t des_ede3_cbc_info;
81
82#endif /* defined(POLARSSL_DES_C) */
83
Paul Bakker6132d0a2012-07-04 17:10:40 +000084#if defined(POLARSSL_BLOWFISH_C)
85extern const cipher_info_t blowfish_cbc_info;
86
87#if defined(POLARSSL_CIPHER_MODE_CFB)
88extern const cipher_info_t blowfish_cfb64_info;
89#endif /* POLARSSL_CIPHER_MODE_CFB */
90
91#if defined(POLARSSL_CIPHER_MODE_CTR)
92extern const cipher_info_t blowfish_ctr_info;
93#endif /* POLARSSL_CIPHER_MODE_CTR */
94#endif /* defined(POLARSSL_BLOWFISH_C) */
95
Paul Bakkerfab5c822012-02-06 16:45:10 +000096#if defined(POLARSSL_CIPHER_NULL_CIPHER)
97extern const cipher_info_t null_cipher_info;
98#endif /* defined(POLARSSL_CIPHER_NULL_CIPHER) */
99
Paul Bakker8123e9d2011-01-06 15:37:30 +0000100#ifdef __cplusplus
101}
102#endif
103
104#endif /* POLARSSL_CIPHER_WRAP_H */