| commit | 630148e67f0cd3d337308321f72f444ca4ef1c35 | [log] [tgz] |
|---|---|---|
| author | Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> | Wed Aug 13 13:57:35 2025 +0200 |
| committer | Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> | Thu Aug 14 09:40:05 2025 +0200 |
| tree | dd0e5f2193260738823b8d79dcc2bed85f312bfc | |
| parent | 7dcfd7373170ef718863c0c61cda4ff3e5e25299 [diff] [blame] |
RSA: use constant-time modinv in deduce_crt() Signed-off-by: Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com>
diff --git a/library/rsa_alt_helpers.c b/library/rsa_alt_helpers.c index feb7874..d91949a 100644 --- a/library/rsa_alt_helpers.c +++ b/library/rsa_alt_helpers.c
@@ -245,7 +245,7 @@ /* QP = Q^{-1} mod P */ if (QP != NULL) { - MBEDTLS_MPI_CHK(mbedtls_mpi_inv_mod(QP, Q, P)); + MBEDTLS_MPI_CHK(mbedtls_mpi_inv_mod_odd(QP, Q, P)); } cleanup: