mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
fix(mbedtls): revert to non constant time rsa key gen
This commit is contained in:
@@ -1423,7 +1423,7 @@ menu "mbedTLS"
|
|||||||
|
|
||||||
config MBEDTLS_CONSTANT_TIME_PRIME_GEN
|
config MBEDTLS_CONSTANT_TIME_PRIME_GEN
|
||||||
bool "Constant-time prime generation"
|
bool "Constant-time prime generation"
|
||||||
default y
|
default n
|
||||||
help
|
help
|
||||||
Use mbedtls' constant-time small-factor test (a
|
Use mbedtls' constant-time small-factor test (a
|
||||||
constant-time GCD against the product of all odd primes up
|
constant-time GCD against the product of all odd primes up
|
||||||
@@ -1440,9 +1440,9 @@ menu "mbedTLS"
|
|||||||
|
|
||||||
If disabled, the variable-time trial division that mbedtls
|
If disabled, the variable-time trial division that mbedtls
|
||||||
used before versions 3.6.7/4.1.1 is used instead,
|
used before versions 3.6.7/4.1.1 is used instead,
|
||||||
restoring key generation performance. Only consider
|
restoring key generation performance.
|
||||||
disabling this if no untrusted code running on the device
|
|
||||||
could observe the timing of key generation operations.
|
Please see issue: https://github.com/Mbed-TLS/mbedtls/issues/10830
|
||||||
|
|
||||||
endmenu # Security hardening
|
endmenu # Security hardening
|
||||||
|
|
||||||
|
|||||||
@@ -261,7 +261,7 @@
|
|||||||
/* mbedtls 4.1.1 made the small-factor test used in prime
|
/* mbedtls 4.1.1 made the small-factor test used in prime
|
||||||
* generation constant-time, which slows RSA key generation down roughly
|
* generation constant-time, which slows RSA key generation down roughly
|
||||||
* tenfold and starves the idle task (the computation never yields the CPU).
|
* tenfold and starves the idle task (the computation never yields the CPU).
|
||||||
* The constant-time variant is the default; when it is explicitly disabled,
|
* The non constant-time variant is the default; when it is disabled,
|
||||||
* fall back to the variable-time trial division from earlier releases. See
|
* fall back to the variable-time trial division from earlier releases. See
|
||||||
* MBEDTLS_MPI_PRIME_SIEVE_VARIABLE_TIME in
|
* MBEDTLS_MPI_PRIME_SIEVE_VARIABLE_TIME in
|
||||||
* tf-psa-crypto/drivers/builtin/src/bignum.c.
|
* tf-psa-crypto/drivers/builtin/src/bignum.c.
|
||||||
|
|||||||
Reference in New Issue
Block a user