SSL Ciphersuites for PolarSSL. More...
#include "pk.h"
#include "cipher.h"
#include "md.h"
Go to the source code of this file.
SSL Ciphersuites for PolarSSL.
Copyright (C) 2006-2013, Brainspark B.V.
This file is part of PolarSSL (http://www.polarssl.org) Lead Maintainer: Paul Bakker <polarssl_maintainer at polarssl.org>
All rights reserved.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
Definition in file ssl_ciphersuites.h.
#define POLARSSL_CIPHERSUITE_WEAK 0x01 |
Definition at line 201 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA 0x8F |
Definition at line 81 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_AES_128_CBC_SHA 0x90 |
Definition at line 82 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_AES_128_CBC_SHA256 0xB2 |
TLS 1.2.
Definition at line 107 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_AES_128_GCM_SHA256 0xAA |
TLS 1.2.
Definition at line 97 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_AES_256_CBC_SHA 0x91 |
Definition at line 83 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_AES_256_CBC_SHA384 0xB3 |
TLS 1.2.
Definition at line 108 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_AES_256_GCM_SHA384 0xAB |
TLS 1.2.
Definition at line 98 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 0xC096 |
TLS 1.2.
Definition at line 180 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_CAMELLIA_128_GCM_SHA256 0xC090 |
TLS 1.2.
Definition at line 173 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 0xC097 |
TLS 1.2.
Definition at line 181 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_CAMELLIA_256_GCM_SHA384 0xC091 |
TLS 1.2.
Definition at line 174 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_NULL_SHA 0x2D |
Weak!
Definition at line 54 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_NULL_SHA256 0xB4 |
Weak! TLS 1.2.
Definition at line 109 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_NULL_SHA384 0xB5 |
Weak! TLS 1.2.
Definition at line 110 of file ssl_ciphersuites.h.
#define TLS_DHE_PSK_WITH_RC4_128_SHA 0x8E |
Definition at line 80 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA 0x16 |
Definition at line 51 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_AES_128_CBC_SHA 0x33 |
Definition at line 58 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_AES_128_CBC_SHA256 0x67 |
TLS 1.2.
Definition at line 69 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_AES_128_GCM_SHA256 0x9E |
TLS 1.2.
Definition at line 92 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_AES_256_CBC_SHA 0x39 |
Definition at line 60 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_AES_256_CBC_SHA256 0x6B |
TLS 1.2.
Definition at line 70 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_AES_256_GCM_SHA384 0x9F |
TLS 1.2.
Definition at line 93 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA 0x45 |
Definition at line 67 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 0xBE |
TLS 1.2.
Definition at line 118 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 0xC07C |
TLS 1.2.
Definition at line 164 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA 0x88 |
Definition at line 73 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 0xC4 |
TLS 1.2.
Definition at line 121 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 0xC07D |
TLS 1.2.
Definition at line 165 of file ssl_ciphersuites.h.
#define TLS_DHE_RSA_WITH_DES_CBC_SHA 0x15 |
Weak! Not in TLS 1.2.
Definition at line 50 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA 0xC008 |
Not in SSL3!
Definition at line 125 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA 0xC009 |
Not in SSL3!
Definition at line 126 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256 0xC023 |
TLS 1.2.
Definition at line 135 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 0xC02B |
TLS 1.2.
Definition at line 141 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA 0xC00A |
Not in SSL3!
Definition at line 127 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384 0xC024 |
TLS 1.2.
Definition at line 136 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 0xC02C |
TLS 1.2.
Definition at line 142 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 0xC072 |
TLS 1.2.
Definition at line 157 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 0xC086 |
TLS 1.2.
Definition at line 166 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 0xC073 |
TLS 1.2.
Definition at line 158 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 0xC087 |
TLS 1.2.
Definition at line 167 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_NULL_SHA 0xC006 |
Weak!
Definition at line 123 of file ssl_ciphersuites.h.
#define TLS_ECDHE_ECDSA_WITH_RC4_128_SHA 0xC007 |
Not in SSL3!
Definition at line 124 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA 0xC034 |
Not in SSL3!
Definition at line 148 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA 0xC035 |
Not in SSL3!
Definition at line 149 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256 0xC037 |
TLS 1.2.
Definition at line 151 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA 0xC036 |
Not in SSL3!
Definition at line 150 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384 0xC038 |
TLS 1.2.
Definition at line 152 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 0xC09A |
TLS 1.2.
Definition at line 184 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 0xC09B |
TLS 1.2.
Definition at line 185 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_NULL_SHA 0xC039 |
Weak! No SSL3!
Definition at line 153 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_NULL_SHA256 0xC03A |
Weak! TLS 1.2.
Definition at line 154 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_NULL_SHA384 0xC03B |
Weak! TLS 1.2.
Definition at line 155 of file ssl_ciphersuites.h.
#define TLS_ECDHE_PSK_WITH_RC4_128_SHA 0xC033 |
Not in SSL3!
Definition at line 147 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA 0xC012 |
Not in SSL3!
Definition at line 131 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA 0xC013 |
Not in SSL3!
Definition at line 132 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256 0xC027 |
TLS 1.2.
Definition at line 138 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 0xC02F |
TLS 1.2.
Definition at line 144 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA 0xC014 |
Not in SSL3!
Definition at line 133 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384 0xC028 |
TLS 1.2.
Definition at line 139 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 0xC030 |
TLS 1.2.
Definition at line 145 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 0xC076 |
TLS 1.2.
Definition at line 159 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 0xC08A |
TLS 1.2.
Definition at line 168 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 0xC077 |
TLS 1.2.
Definition at line 160 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 0xC08B |
TLS 1.2.
Definition at line 169 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_NULL_SHA 0xC010 |
Weak!
Definition at line 129 of file ssl_ciphersuites.h.
#define TLS_ECDHE_RSA_WITH_RC4_128_SHA 0xC011 |
Not in SSL3!
Definition at line 130 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_3DES_EDE_CBC_SHA 0x8B |
Definition at line 76 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_AES_128_CBC_SHA 0x8C |
Definition at line 77 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_AES_128_CBC_SHA256 0xAE |
TLS 1.2.
Definition at line 102 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_AES_128_GCM_SHA256 0xA8 |
TLS 1.2.
Definition at line 95 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_AES_256_CBC_SHA 0x8D |
Definition at line 78 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_AES_256_CBC_SHA384 0xAF |
TLS 1.2.
Definition at line 103 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_AES_256_GCM_SHA384 0xA9 |
TLS 1.2.
Definition at line 96 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256 0xC094 |
TLS 1.2.
Definition at line 178 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256 0xC08D |
TLS 1.2.
Definition at line 171 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384 0xC095 |
TLS 1.2.
Definition at line 179 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384 0xC08F |
TLS 1.2.
Definition at line 172 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_NULL_SHA 0x2C |
Weak!
Definition at line 53 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_NULL_SHA256 0xB0 |
Weak! TLS 1.2.
Definition at line 104 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_NULL_SHA384 0xB1 |
Weak! TLS 1.2.
Definition at line 105 of file ssl_ciphersuites.h.
#define TLS_PSK_WITH_RC4_128_SHA 0x8A |
Definition at line 75 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA 0x93 |
Definition at line 86 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_AES_128_CBC_SHA 0x94 |
Definition at line 87 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_AES_128_CBC_SHA256 0xB6 |
TLS 1.2.
Definition at line 112 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_AES_128_GCM_SHA256 0xAC |
TLS 1.2.
Definition at line 99 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_AES_256_CBC_SHA 0x95 |
Definition at line 88 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_AES_256_CBC_SHA384 0xB7 |
TLS 1.2.
Definition at line 113 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_AES_256_GCM_SHA384 0xAD |
TLS 1.2.
Definition at line 100 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 0xC098 |
TLS 1.2.
Definition at line 182 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256 0xC092 |
TLS 1.2.
Definition at line 175 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 0xC099 |
TLS 1.2.
Definition at line 183 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384 0xC093 |
TLS 1.2.
Definition at line 176 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_NULL_SHA 0x2E |
Weak!
Definition at line 55 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_NULL_SHA256 0xB8 |
Weak! TLS 1.2.
Definition at line 114 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_NULL_SHA384 0xB9 |
Weak! TLS 1.2.
Definition at line 115 of file ssl_ciphersuites.h.
#define TLS_RSA_PSK_WITH_RC4_128_SHA 0x92 |
Definition at line 85 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_3DES_EDE_CBC_SHA 0x0A |
Definition at line 48 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_AES_128_CBC_SHA 0x2F |
Definition at line 56 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_AES_128_CBC_SHA256 0x3C |
TLS 1.2.
Definition at line 63 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_AES_128_GCM_SHA256 0x9C |
TLS 1.2.
Definition at line 90 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_AES_256_CBC_SHA 0x35 |
Definition at line 59 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_AES_256_CBC_SHA256 0x3D |
TLS 1.2.
Definition at line 64 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_AES_256_GCM_SHA384 0x9D |
TLS 1.2.
Definition at line 91 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_CAMELLIA_128_CBC_SHA 0x41 |
Definition at line 66 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256 0xBA |
TLS 1.2.
Definition at line 117 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256 0xC07A |
TLS 1.2.
Definition at line 162 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_CAMELLIA_256_CBC_SHA 0x84 |
Definition at line 72 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256 0xC0 |
TLS 1.2.
Definition at line 120 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384 0xC07B |
TLS 1.2.
Definition at line 163 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_DES_CBC_SHA 0x09 |
Weak! Not in TLS 1.2.
Definition at line 46 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_NULL_MD5 0x01 |
Weak!
Definition at line 41 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_NULL_SHA 0x02 |
Weak!
Definition at line 42 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_NULL_SHA256 0x3B |
Weak!
Definition at line 62 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_RC4_128_MD5 0x04 |
Definition at line 44 of file ssl_ciphersuites.h.
#define TLS_RSA_WITH_RC4_128_SHA 0x05 |
Definition at line 45 of file ssl_ciphersuites.h.
typedef struct _ssl_ciphersuite_t ssl_ciphersuite_t |
Definition at line 199 of file ssl_ciphersuites.h.
enum key_exchange_type_t |
Definition at line 187 of file ssl_ciphersuites.h.
const ssl_ciphersuite_t* ssl_ciphersuite_from_id | ( | int | ciphersuite_id | ) |
Definition at line 1326 of file ssl_ciphersuites.c.
References _ssl_ciphersuite_t::id.
Referenced by ssl_get_ciphersuite_name(), ssl_list_ciphersuites(), ssl_parse_client_hello(), ssl_parse_client_hello_v2(), ssl_parse_server_hello(), and ssl_write_client_hello().
const ssl_ciphersuite_t* ssl_ciphersuite_from_string | ( | const char * | ciphersuite_name | ) |
Definition at line 1308 of file ssl_ciphersuites.c.
References _ssl_ciphersuite_t::id, and _ssl_ciphersuite_t::name.
Referenced by ssl_get_ciphersuite_id().
int ssl_ciphersuite_uses_ec | ( | const ssl_ciphersuite_t * | info | ) |
Definition at line 1385 of file ssl_ciphersuites.c.
References _ssl_ciphersuite_t::key_exchange, POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA, POLARSSL_KEY_EXCHANGE_ECDHE_PSK, and POLARSSL_KEY_EXCHANGE_ECDHE_RSA.
Referenced by ssl_parse_client_hello().
int ssl_ciphersuite_uses_psk | ( | const ssl_ciphersuite_t * | info | ) |
Definition at line 1399 of file ssl_ciphersuites.c.
References _ssl_ciphersuite_t::key_exchange, POLARSSL_KEY_EXCHANGE_DHE_PSK, POLARSSL_KEY_EXCHANGE_ECDHE_PSK, POLARSSL_KEY_EXCHANGE_PSK, and POLARSSL_KEY_EXCHANGE_RSA_PSK.
Referenced by ssl_parse_client_hello().
pk_type_t ssl_get_ciphersuite_sig_pk_alg | ( | const ssl_ciphersuite_t * | info | ) |
Definition at line 1366 of file ssl_ciphersuites.c.
References _ssl_ciphersuite_t::key_exchange, POLARSSL_KEY_EXCHANGE_DHE_RSA, POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA, POLARSSL_KEY_EXCHANGE_ECDHE_RSA, POLARSSL_KEY_EXCHANGE_RSA, POLARSSL_KEY_EXCHANGE_RSA_PSK, POLARSSL_PK_ECDSA, POLARSSL_PK_NONE, and POLARSSL_PK_RSA.
Referenced by ssl_parse_server_key_exchange(), and ssl_pick_cert().
const int* ssl_list_ciphersuites | ( | void | ) |
Returns the list of ciphersuites supported by the SSL/TLS module.
Definition at line 1282 of file ssl_ciphersuites.c.
References ciphersuite_preference, ssl_ciphersuite_from_id(), supported_ciphersuites, and supported_init.