mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2025-03-06 23:59:57 +00:00
Moved mpi_inv_mod() outside POLARSSL_GENPRIME
(cherry picked from commit d9374b05d6
)
Conflicts:
ChangeLog
This commit is contained in:
parent
b3351bd98e
commit
087e0379c5
|
@ -6,6 +6,7 @@ Bugfix
|
||||||
* Handle existence of OpenSSL Trust Extensions at end of X.509 DER blob
|
* Handle existence of OpenSSL Trust Extensions at end of X.509 DER blob
|
||||||
* mpi_add_abs() now correctly handles adding short numbers to long numbers
|
* mpi_add_abs() now correctly handles adding short numbers to long numbers
|
||||||
with carry rollover
|
with carry rollover
|
||||||
|
* Moved mpi_inv_mod() outside POLARSSL_GENPRIME
|
||||||
|
|
||||||
Security
|
Security
|
||||||
* Fixed potential memory zeroization on miscrafted RSA key (found by Eloi
|
* Fixed potential memory zeroization on miscrafted RSA key (found by Eloi
|
||||||
|
|
|
@ -1627,8 +1627,6 @@ cleanup:
|
||||||
return( ret );
|
return( ret );
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(POLARSSL_GENPRIME)
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Modular inverse: X = A^-1 mod N (HAC 14.61 / 14.64)
|
* Modular inverse: X = A^-1 mod N (HAC 14.61 / 14.64)
|
||||||
*/
|
*/
|
||||||
|
@ -1724,6 +1722,8 @@ cleanup:
|
||||||
return( ret );
|
return( ret );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(POLARSSL_GENPRIME)
|
||||||
|
|
||||||
static const int small_prime[] =
|
static const int small_prime[] =
|
||||||
{
|
{
|
||||||
3, 5, 7, 11, 13, 17, 19, 23,
|
3, 5, 7, 11, 13, 17, 19, 23,
|
||||||
|
|
Loading…
Reference in a new issue