mbedtls: re-enable RC4 support (needed by transmission and others)
[openwrt/openwrt.git] / package / libs / mbedtls / patches / 200-config.patch
1 --- a/include/mbedtls/config.h
2 +++ b/include/mbedtls/config.h
3 @@ -191,7 +191,7 @@
4 *
5 * Uncomment to get errors on using deprecated functions.
6 */
7 -//#define MBEDTLS_DEPRECATED_REMOVED
8 +#define MBEDTLS_DEPRECATED_REMOVED
9
10 /* \} name SECTION: System support */
11
12 @@ -347,7 +347,7 @@
13 *
14 * Enable Cipher Feedback mode (CFB) for symmetric ciphers.
15 */
16 -#define MBEDTLS_CIPHER_MODE_CFB
17 +//#define MBEDTLS_CIPHER_MODE_CFB
18
19 /**
20 * \def MBEDTLS_CIPHER_MODE_CTR
21 @@ -441,17 +441,17 @@
22 *
23 * Comment macros to disable the curve and functions for it
24 */
25 -#define MBEDTLS_ECP_DP_SECP192R1_ENABLED
26 -#define MBEDTLS_ECP_DP_SECP224R1_ENABLED
27 +//#define MBEDTLS_ECP_DP_SECP192R1_ENABLED
28 +//#define MBEDTLS_ECP_DP_SECP224R1_ENABLED
29 #define MBEDTLS_ECP_DP_SECP256R1_ENABLED
30 #define MBEDTLS_ECP_DP_SECP384R1_ENABLED
31 -#define MBEDTLS_ECP_DP_SECP521R1_ENABLED
32 -#define MBEDTLS_ECP_DP_SECP192K1_ENABLED
33 -#define MBEDTLS_ECP_DP_SECP224K1_ENABLED
34 +//#define MBEDTLS_ECP_DP_SECP521R1_ENABLED
35 +//#define MBEDTLS_ECP_DP_SECP192K1_ENABLED
36 +//#define MBEDTLS_ECP_DP_SECP224K1_ENABLED
37 #define MBEDTLS_ECP_DP_SECP256K1_ENABLED
38 -#define MBEDTLS_ECP_DP_BP256R1_ENABLED
39 -#define MBEDTLS_ECP_DP_BP384R1_ENABLED
40 -#define MBEDTLS_ECP_DP_BP512R1_ENABLED
41 +//#define MBEDTLS_ECP_DP_BP256R1_ENABLED
42 +//#define MBEDTLS_ECP_DP_BP384R1_ENABLED
43 +//#define MBEDTLS_ECP_DP_BP512R1_ENABLED
44 #define MBEDTLS_ECP_DP_CURVE25519_ENABLED
45
46 /**
47 @@ -476,8 +476,8 @@
48 * Requires: MBEDTLS_HMAC_DRBG_C
49 *
50 * Comment this macro to disable deterministic ECDSA.
51 - */
52 #define MBEDTLS_ECDSA_DETERMINISTIC
53 + */
54
55 /**
56 * \def MBEDTLS_KEY_EXCHANGE_PSK_ENABLED
57 @@ -523,7 +523,7 @@
58 * MBEDTLS_TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA
59 * MBEDTLS_TLS_DHE_PSK_WITH_RC4_128_SHA
60 */
61 -#define MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED
62 +//#define MBEDTLS_KEY_EXCHANGE_DHE_PSK_ENABLED
63
64 /**
65 * \def MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED
66 @@ -542,8 +542,8 @@
67 * MBEDTLS_TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256
68 * MBEDTLS_TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA
69 * MBEDTLS_TLS_ECDHE_PSK_WITH_RC4_128_SHA
70 - */
71 #define MBEDTLS_KEY_EXCHANGE_ECDHE_PSK_ENABLED
72 + */
73
74 /**
75 * \def MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED
76 @@ -568,7 +568,7 @@
77 * MBEDTLS_TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA
78 * MBEDTLS_TLS_RSA_PSK_WITH_RC4_128_SHA
79 */
80 -#define MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED
81 +//#define MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED
82
83 /**
84 * \def MBEDTLS_KEY_EXCHANGE_RSA_ENABLED
85 @@ -695,7 +695,7 @@
86 * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256
87 * MBEDTLS_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384
88 */
89 -#define MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED
90 +//#define MBEDTLS_KEY_EXCHANGE_ECDH_ECDSA_ENABLED
91
92 /**
93 * \def MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED
94 @@ -719,7 +719,7 @@
95 * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256
96 * MBEDTLS_TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384
97 */
98 -#define MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED
99 +//#define MBEDTLS_KEY_EXCHANGE_ECDH_RSA_ENABLED
100
101 /**
102 * \def MBEDTLS_KEY_EXCHANGE_ECJPAKE_ENABLED
103 @@ -823,7 +823,7 @@
104 * This option is only useful if both MBEDTLS_SHA256_C and
105 * MBEDTLS_SHA512_C are defined. Otherwise the available hash module is used.
106 */
107 -//#define MBEDTLS_ENTROPY_FORCE_SHA256
108 +#define MBEDTLS_ENTROPY_FORCE_SHA256
109
110 /**
111 * \def MBEDTLS_ENTROPY_NV_SEED
112 @@ -917,14 +917,14 @@
113 * Uncomment this macro to disable the use of CRT in RSA.
114 *
115 */
116 -//#define MBEDTLS_RSA_NO_CRT
117 +#define MBEDTLS_RSA_NO_CRT
118
119 /**
120 * \def MBEDTLS_SELF_TEST
121 *
122 * Enable the checkup functions (*_self_test).
123 */
124 -#define MBEDTLS_SELF_TEST
125 +//#define MBEDTLS_SELF_TEST
126
127 /**
128 * \def MBEDTLS_SHA256_SMALLER
129 @@ -940,7 +940,7 @@
130 *
131 * Uncomment to enable the smaller implementation of SHA256.
132 */
133 -//#define MBEDTLS_SHA256_SMALLER
134 +#define MBEDTLS_SHA256_SMALLER
135
136 /**
137 * \def MBEDTLS_SSL_ALL_ALERT_MESSAGES
138 @@ -1059,8 +1059,8 @@
139 * misuse/misunderstand.
140 *
141 * Comment this to disable support for renegotiation.
142 - */
143 #define MBEDTLS_SSL_RENEGOTIATION
144 + */
145
146 /**
147 * \def MBEDTLS_SSL_SRV_SUPPORT_SSLV2_CLIENT_HELLO
148 @@ -1234,8 +1234,8 @@
149 * callbacks are provided by MBEDTLS_SSL_TICKET_C.
150 *
151 * Comment this macro to disable support for SSL session tickets
152 - */
153 #define MBEDTLS_SSL_SESSION_TICKETS
154 + */
155
156 /**
157 * \def MBEDTLS_SSL_EXPORT_KEYS
158 @@ -1265,7 +1265,7 @@
159 *
160 * Comment this macro to disable support for truncated HMAC in SSL
161 */
162 -#define MBEDTLS_SSL_TRUNCATED_HMAC
163 +//#define MBEDTLS_SSL_TRUNCATED_HMAC
164
165 /**
166 * \def MBEDTLS_THREADING_ALT
167 @@ -1299,8 +1299,8 @@
168 * Requires: MBEDTLS_VERSION_C
169 *
170 * Comment this to disable run-time checking and save ROM space
171 - */
172 #define MBEDTLS_VERSION_FEATURES
173 + */
174
175 /**
176 * \def MBEDTLS_X509_ALLOW_EXTENSIONS_NON_V3
177 @@ -1621,7 +1621,7 @@
178 * MBEDTLS_TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256
179 * MBEDTLS_TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256
180 */
181 -#define MBEDTLS_CAMELLIA_C
182 +//#define MBEDTLS_CAMELLIA_C
183
184 /**
185 * \def MBEDTLS_CCM_C
186 @@ -1635,7 +1635,7 @@
187 * This module enables the AES-CCM ciphersuites, if other requisites are
188 * enabled as well.
189 */
190 -#define MBEDTLS_CCM_C
191 +//#define MBEDTLS_CCM_C
192
193 /**
194 * \def MBEDTLS_CERTS_C
195 @@ -1647,7 +1647,7 @@
196 *
197 * This module is used for testing (ssl_client/server).
198 */
199 -#define MBEDTLS_CERTS_C
200 +//#define MBEDTLS_CERTS_C
201
202 /**
203 * \def MBEDTLS_CIPHER_C
204 @@ -1700,7 +1700,7 @@
205 *
206 * This module provides debugging functions.
207 */
208 -#define MBEDTLS_DEBUG_C
209 +//#define MBEDTLS_DEBUG_C
210
211 /**
212 * \def MBEDTLS_DES_C
213 @@ -1725,8 +1725,8 @@
214 * MBEDTLS_TLS_PSK_WITH_3DES_EDE_CBC_SHA
215 *
216 * PEM_PARSE uses DES/3DES for decrypting encrypted keys.
217 - */
218 #define MBEDTLS_DES_C
219 + */
220
221 /**
222 * \def MBEDTLS_DHM_C
223 @@ -1880,8 +1880,8 @@
224 * Requires: MBEDTLS_MD_C
225 *
226 * Uncomment to enable the HMAC_DRBG random number geerator.
227 - */
228 #define MBEDTLS_HMAC_DRBG_C
229 + */
230
231 /**
232 * \def MBEDTLS_MD_C
233 @@ -2158,7 +2158,7 @@
234 * Caller: library/mbedtls_md.c
235 *
236 */
237 -#define MBEDTLS_RIPEMD160_C
238 +//#define MBEDTLS_RIPEMD160_C
239
240 /**
241 * \def MBEDTLS_RSA_C
242 @@ -2235,8 +2235,8 @@
243 * Caller:
244 *
245 * Requires: MBEDTLS_SSL_CACHE_C
246 - */
247 #define MBEDTLS_SSL_CACHE_C
248 + */
249
250 /**
251 * \def MBEDTLS_SSL_COOKIE_C
252 @@ -2257,8 +2257,8 @@
253 * Caller:
254 *
255 * Requires: MBEDTLS_CIPHER_C
256 - */
257 #define MBEDTLS_SSL_TICKET_C
258 + */
259
260 /**
261 * \def MBEDTLS_SSL_CLI_C
262 @@ -2357,8 +2357,8 @@
263 * Module: library/version.c
264 *
265 * This module provides run-time version information.
266 - */
267 #define MBEDTLS_VERSION_C
268 + */
269
270 /**
271 * \def MBEDTLS_X509_USE_C
272 @@ -2468,7 +2468,7 @@
273 * Module: library/xtea.c
274 * Caller:
275 */
276 -#define MBEDTLS_XTEA_C
277 +//#define MBEDTLS_XTEA_C
278
279 /* \} name SECTION: mbed TLS modules */
280