mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2025-03-24 10:35:12 +00:00
Emit deprecation warning if MBEDTLS_RSA_FORCE_BLINDING is not set
This commit is contained in:
parent
6ac972d815
commit
a988a2702a
|
@ -66,6 +66,13 @@
|
||||||
#define mbedtls_free free
|
#define mbedtls_free free
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if !defined(MBEDTLS_RSA_FORCE_BLINDING) && \
|
||||||
|
defined(MBEDTLS_DEPRECATED_WARNING)
|
||||||
|
#warning Not enforcing blinding checks for RSA private key operations\
|
||||||
|
is deprecated. Please uncomment MBEDTLS_RSA_FORCE_BLINDING\
|
||||||
|
in config.h to enforce blinding checks.
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Implementation that should never be optimized out by the compiler */
|
/* Implementation that should never be optimized out by the compiler */
|
||||||
static void mbedtls_zeroize( void *v, size_t n ) {
|
static void mbedtls_zeroize( void *v, size_t n ) {
|
||||||
volatile unsigned char *p = (unsigned char*)v; while( n-- ) *p++ = 0;
|
volatile unsigned char *p = (unsigned char*)v; while( n-- ) *p++ = 0;
|
||||||
|
|
Loading…
Reference in a new issue