PolarSSL v1.3.9
config-suite-b.h
Go to the documentation of this file.
1 /*
2  * Minimal configuration for TLS NSA Suite B Profile (RFC 6460)
3  *
4  * Distinguishing features:
5  * - no RSA or classic DH, fully based on ECC
6  * - optimized for low RAM usage
7  *
8  * Possible improvements:
9  * - if 128-bit security is enough, disable secp384r1 and SHA-512
10  * - use embedded certs in DER format and disable PEM_PARSE_C and BASE64_C
11  *
12  * See README.txt for usage instructions.
13  */
14 
15 #ifndef POLARSSL_CONFIG_H
16 #define POLARSSL_CONFIG_H
17 
18 /* System support */
19 #define POLARSSL_HAVE_ASM
20 #define POLARSSL_HAVE_TIME
21 #define POLARSSL_HAVE_IPV6
22 
23 /* PolarSSL feature support */
24 #define POLARSSL_ECP_DP_SECP256R1_ENABLED
25 #define POLARSSL_ECP_DP_SECP384R1_ENABLED
26 #define POLARSSL_KEY_EXCHANGE_ECDHE_ECDSA_ENABLED
27 #define POLARSSL_SSL_PROTO_TLS1_2
28 
29 /* PolarSSL modules */
30 #define POLARSSL_AES_C
31 #define POLARSSL_ASN1_PARSE_C
32 #define POLARSSL_ASN1_WRITE_C
33 #define POLARSSL_BIGNUM_C
34 #define POLARSSL_CIPHER_C
35 #define POLARSSL_CTR_DRBG_C
36 #define POLARSSL_ECDH_C
37 #define POLARSSL_ECDSA_C
38 #define POLARSSL_ECP_C
39 #define POLARSSL_ENTROPY_C
40 #define POLARSSL_GCM_C
41 #define POLARSSL_MD_C
42 #define POLARSSL_NET_C
43 #define POLARSSL_OID_C
44 #define POLARSSL_PK_C
45 #define POLARSSL_PK_PARSE_C
46 #define POLARSSL_SHA256_C
47 #define POLARSSL_SHA512_C
48 #define POLARSSL_SSL_CLI_C
49 #define POLARSSL_SSL_SRV_C
50 #define POLARSSL_SSL_TLS_C
51 #define POLARSSL_X509_CRT_PARSE_C
52 #define POLARSSL_X509_USE_C
53 
54 /* For test certificates */
55 #define POLARSSL_BASE64_C
56 #define POLARSSL_CERTS_C
57 #define POLARSSL_PEM_PARSE_C
58 
59 /* Save RAM at the expense of ROM */
60 #define POLARSSL_AES_ROM_TABLES
61 
62 /* Save RAM by adjusting to our exact needs */
63 #define POLARSSL_ECP_MAX_BITS 384
64 #define POLARSSL_MPI_MAX_SIZE 48 // 384 bits is 48 bytes
65 
66 /* Save RAM at the expense of speed, see ecp.h */
67 #define POLARSSL_ECP_WINDOW_SIZE 2
68 #define POLARSSL_ECP_FIXED_POINT_OPTIM 0
69 
70 /* Uncomment for a significant speed benefit at the expense of some ROM */
71 //#define POLARSSL_ECP_NIST_OPTIM
72 
73 /*
74  * You should adjust this to the exact number of sources you're using: default
75  * is the "platform_entropy_poll" source, but you may want to add other ones.
76  * Minimum is 2 for the entropy test suite.
77  */
78 #define ENTROPY_MAX_SOURCES 2
79 
80 /* Save ROM and a few bytes of RAM by specifying our own ciphersuite list */
81 #define SSL_CIPHERSUITES \
82  TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384, \
83  TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
84 
85 /*
86  * Save RAM at the expense of interoperability: do this only if you control
87  * both ends of the connection! (See coments in "polarssl/ssl.h".)
88  * The minimum size here depends on the certificate chain used as well as the
89  * typical size of records.
90  */
91 #define SSL_MAX_CONTENT_LEN 1024
92 
93 #include "polarssl/check_config.h"
94 
95 #endif /* POLARSSL_CONFIG_H */
Consistency checks for configuration options.