mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-29 11:41:15 +03:00
Fix failures in psa_cryto_driver_wrappers suite
- "in-driver" test should depend on the present of a driver. - add new counter in key manangement driver test hook which counts the calls of generate_key. - We only care about the hits when processing `psa_generate_key`. Signed-off-by: Pengyu Lv <pengyu.lv@arm.com>
This commit is contained in:
committed by
Manuel Pégourié-Gonnard
parent
a44cab020e
commit
3bb89dc935
@ -26,8 +26,10 @@ typedef struct {
|
||||
/* Count the amount of times one of the key management driver functions
|
||||
* is called. */
|
||||
unsigned long hits;
|
||||
/* Subset of hits which only counts key operations with EC key */
|
||||
/* Subset of hits which only counts public key export operations */
|
||||
unsigned long hits_export_public_key;
|
||||
/* Subset of hits which only counts key generation operations */
|
||||
unsigned long hits_generate_key;
|
||||
/* Location of the last key management driver called to import a key. */
|
||||
psa_key_location_t location;
|
||||
} mbedtls_test_driver_key_management_hooks_t;
|
||||
@ -36,7 +38,7 @@ typedef struct {
|
||||
* sense that no PSA specification will assign a meaning to this location
|
||||
* (stated first in version 1.0.1 of the specification) and that it is not
|
||||
* used as a location of an opaque test drivers. */
|
||||
#define MBEDTLS_TEST_DRIVER_KEY_MANAGEMENT_INIT { NULL, 0, PSA_SUCCESS, 0, 0, 0x800000 }
|
||||
#define MBEDTLS_TEST_DRIVER_KEY_MANAGEMENT_INIT { NULL, 0, PSA_SUCCESS, 0, 0, 0, 0x800000 }
|
||||
static inline mbedtls_test_driver_key_management_hooks_t
|
||||
mbedtls_test_driver_key_management_hooks_init(void)
|
||||
{
|
||||
|
Reference in New Issue
Block a user