Skip to content

Commit 4164b17

Browse files
d3zd3zgalak
authored andcommitted
modules: mbedtls: Enable PKCS1 v2.1
This Mbed TLS configuration option was being selected based on a non-existent Kconfig option, and hence would never be defined. v2.1 of PKCS1 was published in 2003. Use of v1.5 has been deprecated since 2016, and should not be used in new or existing designs. Enable the v2.1 version in any situation where RSA is used for signatures. In the future, we should disable v1.5 entirely, but only after all uses have been determined and possibly corrected. No significant weaknesses have been found in v1.5, however v2.1 has a significant security proof. However, v2.1 does require an entropy source, which may be an issue in some embedded device situations (which likely are problematic for other cryptographic reasons). Signed-off-by: David Brown <[email protected]>
1 parent 22360ee commit 4164b17

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

modules/mbedtls/configs/config-tls-generic.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -305,10 +305,6 @@
305305
#define MBEDTLS_CIPHER_C
306306
#endif
307307

308-
#if defined(CONFIG_MBEDTLS_PKCS1_V21_ENABLED)
309-
#define MBEDTLS_PKCS1_V21
310-
#endif
311-
312308
#if defined(CONFIG_MBEDTLS_MD)
313309
#define MBEDTLS_MD_C
314310
#endif
@@ -340,6 +336,7 @@
340336
defined(MBEDTLS_KEY_EXCHANGE_DHE_RSA_ENABLED) || \
341337
defined(MBEDTLS_KEY_EXCHANGE_ECDHE_RSA_ENABLED)
342338
#define MBEDTLS_PKCS1_V15
339+
#define MBEDTLS_PKCS1_V21
343340
#endif
344341

345342
#if defined(MBEDTLS_KEY_EXCHANGE_RSA_PSK_ENABLED) || \

0 commit comments

Comments
 (0)