mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-30 22:43:08 +03:00
test_driver_cipher: add forced return status for encrypt and set_iv
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
This commit is contained in:
@ -23,13 +23,17 @@ typedef struct {
|
||||
/* If not PSA_SUCCESS, return this error code instead of processing the
|
||||
* function call. */
|
||||
psa_status_t forced_status;
|
||||
psa_status_t forced_status_encrypt;
|
||||
psa_status_t forced_status_set_iv;
|
||||
/* Count the amount of times one of the cipher driver functions is called. */
|
||||
unsigned long hits;
|
||||
unsigned long cipher_encrypt_hits;
|
||||
unsigned long cipher_update_forced_status_hits;
|
||||
unsigned long hits_encrypt;
|
||||
unsigned long hits_set_iv;
|
||||
} mbedtls_test_driver_cipher_hooks_t;
|
||||
|
||||
#define MBEDTLS_TEST_DRIVER_CIPHER_INIT { NULL, 0, PSA_SUCCESS, 0, 0, 0 }
|
||||
#define MBEDTLS_TEST_DRIVER_CIPHER_INIT { NULL, 0, \
|
||||
PSA_SUCCESS, PSA_SUCCESS, PSA_SUCCESS, \
|
||||
0, 0, 0 }
|
||||
static inline mbedtls_test_driver_cipher_hooks_t
|
||||
mbedtls_test_driver_cipher_hooks_init(void)
|
||||
{
|
||||
|
Reference in New Issue
Block a user