Add LMOTS test hook to header

Signed-off-by: Raef Coles <raef.coles@arm.com>
This commit is contained in:
Raef Coles 2022-09-27 10:23:53 +01:00
parent 403558c1c9
commit 40158e11fc
No known key found for this signature in database
GPG key ID: 1AAF1B43DF2086F4
2 changed files with 4 additions and 2 deletions

View file

@ -139,6 +139,10 @@ typedef struct {
} mbedtls_lmots_private_t; } mbedtls_lmots_private_t;
#endif /* MBEDTLS_LMS_PRIVATE */ #endif /* MBEDTLS_LMS_PRIVATE */
#if defined(MBEDTLS_TEST_HOOKS)
extern int( *mbedtls_lmots_sign_private_key_invalidated_hook )( unsigned char * );
#endif /* defined(MBEDTLS_TEST_HOOKS) */
/** /**
* \brief This function converts an unsigned int into a * \brief This function converts an unsigned int into a
* network-byte-order (big endian) string. * network-byte-order (big endian) string.

View file

@ -3,8 +3,6 @@
#include "mbedtls/lms.h" #include "mbedtls/lms.h"
#if defined(MBEDTLS_TEST_HOOKS) #if defined(MBEDTLS_TEST_HOOKS)
extern int( *mbedtls_lmots_sign_private_key_invalidated_hook )( unsigned char * );
int check_lmots_private_key_for_leak(unsigned char * sig) int check_lmots_private_key_for_leak(unsigned char * sig)
{ {
size_t idx; size_t idx;