blob: a85f8fdb24c9f31d2ccf9fddc126015afad10681 [file] [log] [blame]
Paul Bakker5121ce52009-01-03 21:22:43 +00001/**
2 * \file config.h
3 *
Paul Bakkere0ccd0a2009-01-04 16:27:10 +00004 * Based on XySSL: Copyright (C) 2006-2008 Christophe Devine
5 *
6 * Copyright (C) 2009 Paul Bakker
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License along
19 * with this program; if not, write to the Free Software Foundation, Inc.,
20 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21 *
Paul Bakker5121ce52009-01-03 21:22:43 +000022 * This set of compile-time options may be used to enable
23 * or disable features selectively, and reduce the global
24 * memory footprint.
25 */
Paul Bakker40e46942009-01-03 21:51:57 +000026#ifndef POLARSSL_CONFIG_H
27#define POLARSSL_CONFIG_H
Paul Bakker5121ce52009-01-03 21:22:43 +000028
29#ifndef _CRT_SECURE_NO_DEPRECATE
30#define _CRT_SECURE_NO_DEPRECATE 1
31#endif
32
33/*
34 * Uncomment if native integers are 8-bit wide.
35 *
Paul Bakker40e46942009-01-03 21:51:57 +000036#define POLARSSL_HAVE_INT8
Paul Bakker5121ce52009-01-03 21:22:43 +000037 */
38
39/*
40 * Uncomment if native integers are 16-bit wide.
41 *
Paul Bakker40e46942009-01-03 21:51:57 +000042#define POLARSSL_HAVE_INT16
Paul Bakker5121ce52009-01-03 21:22:43 +000043 */
44
45/*
46 * Uncomment if the compiler supports long long.
47 *
Paul Bakker40e46942009-01-03 21:51:57 +000048#define POLARSSL_HAVE_LONGLONG
Paul Bakker5121ce52009-01-03 21:22:43 +000049 */
50
51/*
52 * Uncomment to enable the use of assembly code.
53 */
Paul Bakker40e46942009-01-03 21:51:57 +000054#define POLARSSL_HAVE_ASM
Paul Bakker5121ce52009-01-03 21:22:43 +000055
56/*
57 * Uncomment if the CPU supports SSE2 (IA-32 specific).
58 *
Paul Bakker40e46942009-01-03 21:51:57 +000059#define POLARSSL_HAVE_SSE2
Paul Bakker5121ce52009-01-03 21:22:43 +000060 */
61
62/*
63 * Enable all SSL/TLS debugging messages.
64 */
Paul Bakker40e46942009-01-03 21:51:57 +000065#define POLARSSL_DEBUG_MSG
Paul Bakker5121ce52009-01-03 21:22:43 +000066
67/*
68 * Enable the checkup functions (*_self_test).
69 */
Paul Bakker40e46942009-01-03 21:51:57 +000070#define POLARSSL_SELF_TEST
Paul Bakker5121ce52009-01-03 21:22:43 +000071
72/*
73 * Enable the prime-number generation code.
74 */
Paul Bakker40e46942009-01-03 21:51:57 +000075#define POLARSSL_GENPRIME
Paul Bakker5121ce52009-01-03 21:22:43 +000076
77/*
78 * Uncomment this macro to store the AES tables in ROM.
79 *
Paul Bakker40e46942009-01-03 21:51:57 +000080#define POLARSSL_AES_ROM_TABLES
Paul Bakker5121ce52009-01-03 21:22:43 +000081 */
82
83/*
84 * Module: library/aes.c
85 * Caller: library/ssl_tls.c
86 *
87 * This module enables the following ciphersuites:
88 * SSL_RSA_AES_128_SHA
89 * SSL_RSA_AES_256_SHA
90 * SSL_EDH_RSA_AES_256_SHA
91 */
Paul Bakker40e46942009-01-03 21:51:57 +000092#define POLARSSL_AES_C
Paul Bakker5121ce52009-01-03 21:22:43 +000093
94/*
95 * Module: library/arc4.c
96 * Caller: library/ssl_tls.c
97 *
98 * This module enables the following ciphersuites:
99 * SSL_RSA_RC4_128_MD5
100 * SSL_RSA_RC4_128_SHA
101 */
Paul Bakker40e46942009-01-03 21:51:57 +0000102#define POLARSSL_ARC4_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000103
104/*
105 * Module: library/base64.c
106 * Caller: library/x509parse.c
107 *
108 * This module is required for X.509 support.
109 */
Paul Bakker40e46942009-01-03 21:51:57 +0000110#define POLARSSL_BASE64_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000111
112/*
113 * Module: library/bignum.c
114 * Caller: library/dhm.c
115 * library/rsa.c
116 * library/ssl_tls.c
117 * library/x509parse.c
118 *
119 * This module is required for RSA and DHM support.
120 */
Paul Bakker40e46942009-01-03 21:51:57 +0000121#define POLARSSL_BIGNUM_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000122
123/*
124 * Module: library/certs.c
125 * Caller:
126 *
127 * This module is used for testing (ssl_client/server).
128 */
Paul Bakker40e46942009-01-03 21:51:57 +0000129#define POLARSSL_CERTS_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000130
131/*
132 * Module: library/debug.c
133 * Caller: library/ssl_cli.c
134 * library/ssl_srv.c
135 * library/ssl_tls.c
136 *
137 * This module provides debugging functions.
138 */
Paul Bakker40e46942009-01-03 21:51:57 +0000139#define POLARSSL_DEBUG_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000140
141/*
142 * Module: library/des.c
143 * Caller: library/ssl_tls.c
144 *
145 * This module enables the following ciphersuites:
146 * SSL_RSA_DES_168_SHA
147 * SSL_EDH_RSA_DES_168_SHA
148 */
Paul Bakker40e46942009-01-03 21:51:57 +0000149#define POLARSSL_DES_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000150
151/*
152 * Module: library/dhm.c
153 * Caller: library/ssl_cli.c
154 * library/ssl_srv.c
155 *
156 * This module enables the following ciphersuites:
157 * SSL_EDH_RSA_DES_168_SHA
158 * SSL_EDH_RSA_AES_256_SHA
159 */
Paul Bakker40e46942009-01-03 21:51:57 +0000160#define POLARSSL_DHM_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000161
162/*
163 * Module: library/havege.c
164 * Caller:
165 *
166 * This module enables the HAVEGE random number generator.
167 */
Paul Bakker40e46942009-01-03 21:51:57 +0000168#define POLARSSL_HAVEGE_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000169
170/*
171 * Module: library/md2.c
172 * Caller: library/x509parse.c
173 *
174 * Uncomment to enable support for (rare) MD2-signed X.509 certs.
175 *
Paul Bakker40e46942009-01-03 21:51:57 +0000176#define POLARSSL_MD2_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000177 */
178
179/*
180 * Module: library/md4.c
181 * Caller: library/x509parse.c
182 *
183 * Uncomment to enable support for (rare) MD4-signed X.509 certs.
184 *
Paul Bakker40e46942009-01-03 21:51:57 +0000185#define POLARSSL_MD4_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000186 */
187
188/*
189 * Module: library/md5.c
190 * Caller: library/ssl_tls.c
191 * library/x509parse.c
192 *
193 * This module is required for SSL/TLS and X.509.
194 */
Paul Bakker40e46942009-01-03 21:51:57 +0000195#define POLARSSL_MD5_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000196
197/*
198 * Module: library/net.c
199 * Caller:
200 *
201 * This module provides TCP/IP networking routines.
202 */
Paul Bakker40e46942009-01-03 21:51:57 +0000203#define POLARSSL_NET_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000204
205/*
206 * Module: library/padlock.c
207 * Caller: library/aes.c
208 *
209 * This modules adds support for the VIA PadLock on x86.
210 */
Paul Bakker40e46942009-01-03 21:51:57 +0000211#define POLARSSL_PADLOCK_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000212
213/*
214 * Module: library/rsa.c
215 * Caller: library/ssl_cli.c
216 * library/ssl_srv.c
217 * library/ssl_tls.c
218 * library/x509.c
219 *
220 * This module is required for SSL/TLS and MD5-signed certificates.
221 */
Paul Bakker40e46942009-01-03 21:51:57 +0000222#define POLARSSL_RSA_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000223
224/*
225 * Module: library/sha1.c
226 * Caller: library/ssl_cli.c
227 * library/ssl_srv.c
228 * library/ssl_tls.c
229 * library/x509parse.c
230 *
231 * This module is required for SSL/TLS and SHA1-signed certificates.
232 */
Paul Bakker40e46942009-01-03 21:51:57 +0000233#define POLARSSL_SHA1_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000234
235/*
236 * Module: library/sha2.c
237 * Caller:
238 *
239 * This module adds support for SHA-224 and SHA-256.
240 */
Paul Bakker40e46942009-01-03 21:51:57 +0000241#define POLARSSL_SHA2_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000242
243/*
244 * Module: library/sha4.c
245 * Caller:
246 *
247 * This module adds support for SHA-384 and SHA-512.
248 */
Paul Bakker40e46942009-01-03 21:51:57 +0000249#define POLARSSL_SHA4_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000250
251/*
252 * Module: library/ssl_cli.c
253 * Caller:
254 *
255 * This module is required for SSL/TLS client support.
256 */
Paul Bakker40e46942009-01-03 21:51:57 +0000257#define POLARSSL_SSL_CLI_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000258
259/*
260 * Module: library/ssl_srv.c
261 * Caller:
262 *
263 * This module is required for SSL/TLS server support.
264 */
Paul Bakker40e46942009-01-03 21:51:57 +0000265#define POLARSSL_SSL_SRV_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000266
267/*
268 * Module: library/ssl_tls.c
269 * Caller: library/ssl_cli.c
270 * library/ssl_srv.c
271 *
272 * This module is required for SSL/TLS.
273 */
Paul Bakker40e46942009-01-03 21:51:57 +0000274#define POLARSSL_SSL_TLS_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000275
276/*
277 * Module: library/timing.c
278 * Caller: library/havege.c
279 *
280 * This module is used by the HAVEGE random number generator.
281 */
Paul Bakker40e46942009-01-03 21:51:57 +0000282#define POLARSSL_TIMING_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000283
284/*
285 * Module: library/x509parse.c
286 * Caller: library/ssl_cli.c
287 * library/ssl_srv.c
288 * library/ssl_tls.c
289 *
290 * This module is required for X.509 certificate parsing.
291 */
Paul Bakker40e46942009-01-03 21:51:57 +0000292#define POLARSSL_X509_PARSE_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000293
294/*
295 * Module: library/x509_write.c
296 * Caller:
297 *
298 * This module is required for X.509 certificate writing.
299 */
Paul Bakker40e46942009-01-03 21:51:57 +0000300#define POLARSSL_X509_WRITE_C
Paul Bakker5121ce52009-01-03 21:22:43 +0000301
Paul Bakker7a7c78f2009-01-04 18:15:48 +0000302/*
303 * Module: library/xtea.c
304 * Caller:
305 */
306#define POLARSSL_XTEA_C
307
Paul Bakker5121ce52009-01-03 21:22:43 +0000308#endif /* config.h */