Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 1 | /** |
| 2 | * \file cipher_wrap.h |
| 3 | * |
| 4 | * \brief Cipher wrappers. |
| 5 | * |
| 6 | * \author Adriaan de Jong <dejong@fox-it.com> |
| 7 | * |
Paul Bakker | 68884e3 | 2013-01-07 18:20:04 +0100 | [diff] [blame] | 8 | * Copyright (C) 2006-2013, Brainspark B.V. |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 9 | * |
| 10 | * This file is part of PolarSSL (http://www.polarssl.org) |
| 11 | * Lead Maintainer: Paul Bakker <polarssl_maintainer at polarssl.org> |
| 12 | * |
| 13 | * All rights reserved. |
| 14 | * |
| 15 | * This program is free software; you can redistribute it and/or modify |
| 16 | * it under the terms of the GNU General Public License as published by |
| 17 | * the Free Software Foundation; either version 2 of the License, or |
| 18 | * (at your option) any later version. |
| 19 | * |
| 20 | * This program is distributed in the hope that it will be useful, |
| 21 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 22 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 23 | * GNU General Public License for more details. |
| 24 | * |
| 25 | * You should have received a copy of the GNU General Public License along |
| 26 | * with this program; if not, write to the Free Software Foundation, Inc., |
| 27 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
| 28 | */ |
Paul Bakker | cce9d77 | 2011-11-18 14:26:47 +0000 | [diff] [blame] | 29 | #ifndef POLARSSL_CIPHER_WRAP_H |
| 30 | #define POLARSSL_CIPHER_WRAP_H |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 31 | |
Paul Bakker | 314052f | 2011-08-15 09:07:52 +0000 | [diff] [blame] | 32 | #include "config.h" |
| 33 | #include "cipher.h" |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 34 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 35 | #ifdef __cplusplus |
| 36 | extern "C" { |
| 37 | #endif |
| 38 | |
| 39 | #if defined(POLARSSL_AES_C) |
| 40 | |
Paul Bakker | 5e0efa7 | 2013-09-08 23:04:04 +0200 | [diff] [blame^] | 41 | extern const cipher_info_t aes_128_ecb_info; |
| 42 | extern const cipher_info_t aes_192_ecb_info; |
| 43 | extern const cipher_info_t aes_256_ecb_info; |
| 44 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 45 | extern const cipher_info_t aes_128_cbc_info; |
| 46 | extern const cipher_info_t aes_192_cbc_info; |
| 47 | extern const cipher_info_t aes_256_cbc_info; |
| 48 | |
Paul Bakker | 343a870 | 2011-06-09 14:27:58 +0000 | [diff] [blame] | 49 | #if defined(POLARSSL_CIPHER_MODE_CFB) |
| 50 | extern const cipher_info_t aes_128_cfb128_info; |
| 51 | extern const cipher_info_t aes_192_cfb128_info; |
| 52 | extern const cipher_info_t aes_256_cfb128_info; |
| 53 | #endif /* POLARSSL_CIPHER_MODE_CFB */ |
| 54 | |
| 55 | #if defined(POLARSSL_CIPHER_MODE_CTR) |
| 56 | extern const cipher_info_t aes_128_ctr_info; |
| 57 | extern const cipher_info_t aes_192_ctr_info; |
| 58 | extern const cipher_info_t aes_256_ctr_info; |
| 59 | #endif /* POLARSSL_CIPHER_MODE_CTR */ |
| 60 | |
Paul Bakker | 68884e3 | 2013-01-07 18:20:04 +0100 | [diff] [blame] | 61 | #if defined(POLARSSL_GCM_C) |
| 62 | extern const cipher_info_t aes_128_gcm_info; |
Manuel Pégourié-Gonnard | 83f3fc0 | 2013-09-04 12:07:24 +0200 | [diff] [blame] | 63 | extern const cipher_info_t aes_192_gcm_info; |
Paul Bakker | 68884e3 | 2013-01-07 18:20:04 +0100 | [diff] [blame] | 64 | extern const cipher_info_t aes_256_gcm_info; |
| 65 | #endif /* POLARSSL_GCM_C */ |
| 66 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 67 | #endif /* defined(POLARSSL_AES_C) */ |
| 68 | |
| 69 | #if defined(POLARSSL_CAMELLIA_C) |
| 70 | |
Paul Bakker | 5e0efa7 | 2013-09-08 23:04:04 +0200 | [diff] [blame^] | 71 | extern const cipher_info_t camellia_128_ecb_info; |
| 72 | extern const cipher_info_t camellia_192_ecb_info; |
| 73 | extern const cipher_info_t camellia_256_ecb_info; |
| 74 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 75 | extern const cipher_info_t camellia_128_cbc_info; |
| 76 | extern const cipher_info_t camellia_192_cbc_info; |
| 77 | extern const cipher_info_t camellia_256_cbc_info; |
| 78 | |
Paul Bakker | 343a870 | 2011-06-09 14:27:58 +0000 | [diff] [blame] | 79 | #if defined(POLARSSL_CIPHER_MODE_CFB) |
| 80 | extern const cipher_info_t camellia_128_cfb128_info; |
| 81 | extern const cipher_info_t camellia_192_cfb128_info; |
| 82 | extern const cipher_info_t camellia_256_cfb128_info; |
| 83 | #endif /* POLARSSL_CIPHER_MODE_CFB */ |
| 84 | |
| 85 | #if defined(POLARSSL_CIPHER_MODE_CTR) |
| 86 | extern const cipher_info_t camellia_128_ctr_info; |
| 87 | extern const cipher_info_t camellia_192_ctr_info; |
| 88 | extern const cipher_info_t camellia_256_ctr_info; |
| 89 | #endif /* POLARSSL_CIPHER_MODE_CTR */ |
| 90 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 91 | #endif /* defined(POLARSSL_CAMELLIA_C) */ |
| 92 | |
| 93 | #if defined(POLARSSL_DES_C) |
| 94 | |
Paul Bakker | 5e0efa7 | 2013-09-08 23:04:04 +0200 | [diff] [blame^] | 95 | extern const cipher_info_t des_ecb_info; |
| 96 | extern const cipher_info_t des_ede_ecb_info; |
| 97 | extern const cipher_info_t des_ede3_ecb_info; |
| 98 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 99 | extern const cipher_info_t des_cbc_info; |
| 100 | extern const cipher_info_t des_ede_cbc_info; |
| 101 | extern const cipher_info_t des_ede3_cbc_info; |
| 102 | |
| 103 | #endif /* defined(POLARSSL_DES_C) */ |
| 104 | |
Paul Bakker | 6132d0a | 2012-07-04 17:10:40 +0000 | [diff] [blame] | 105 | #if defined(POLARSSL_BLOWFISH_C) |
Paul Bakker | 5e0efa7 | 2013-09-08 23:04:04 +0200 | [diff] [blame^] | 106 | extern const cipher_info_t blowfish_ecb_info; |
Paul Bakker | 6132d0a | 2012-07-04 17:10:40 +0000 | [diff] [blame] | 107 | extern const cipher_info_t blowfish_cbc_info; |
| 108 | |
| 109 | #if defined(POLARSSL_CIPHER_MODE_CFB) |
| 110 | extern const cipher_info_t blowfish_cfb64_info; |
| 111 | #endif /* POLARSSL_CIPHER_MODE_CFB */ |
| 112 | |
| 113 | #if defined(POLARSSL_CIPHER_MODE_CTR) |
| 114 | extern const cipher_info_t blowfish_ctr_info; |
| 115 | #endif /* POLARSSL_CIPHER_MODE_CTR */ |
| 116 | #endif /* defined(POLARSSL_BLOWFISH_C) */ |
| 117 | |
Paul Bakker | 68884e3 | 2013-01-07 18:20:04 +0100 | [diff] [blame] | 118 | #if defined(POLARSSL_ARC4_C) |
| 119 | extern const cipher_info_t arc4_128_info; |
| 120 | #endif /* defined(POLARSSL_ARC4_C) */ |
| 121 | |
Paul Bakker | fab5c82 | 2012-02-06 16:45:10 +0000 | [diff] [blame] | 122 | #if defined(POLARSSL_CIPHER_NULL_CIPHER) |
| 123 | extern const cipher_info_t null_cipher_info; |
| 124 | #endif /* defined(POLARSSL_CIPHER_NULL_CIPHER) */ |
| 125 | |
Paul Bakker | 8123e9d | 2011-01-06 15:37:30 +0000 | [diff] [blame] | 126 | #ifdef __cplusplus |
| 127 | } |
| 128 | #endif |
| 129 | |
| 130 | #endif /* POLARSSL_CIPHER_WRAP_H */ |