mbedtls_psa_mac_sign_setup() function
Set up a multipart MAC calculation operation using Mbed TLS.
Arguments
operation
The operation object to set up. It must have been initialized and not yet in use.
attributes
The attributes of the key to use for the operation.
key_buffer
The buffer containing the key to use for computing the MAC. This buffer contains the key in export representation as defined by psa_export_key() (i.e. the raw key bytes).
key_buffer_size
Size of the \p key_buffer buffer in bytes.
alg
The MAC algorithm to use (\c PSA_ALG_XXX value such that #PSA_ALG_IS_MAC(\p alg) is true).
Return value
#PSA_SUCCESS Success. #PSA_ERROR_NOT_SUPPORTED \p alg is not supported. #PSA_ERROR_INSUFFICIENT_MEMORY \emptydescription #PSA_ERROR_CORRUPTION_DETECTED \emptydescription #PSA_ERROR_BAD_STATE The operation state is not valid (it must be inactive).
Notes
The signature of this function is that of a PSA driver mac_sign_setup entry point. This function behaves as a mac_sign_setup entry point as defined in the PSA driver interface specification for transparent drivers.
mbedtls_psa_mac_sign_setup() is called by 1 function and calls 1 function:
![]()
mbedtls_psa_mac_sign_setup()
mbedtls_psa_mac_sign_setup():
![]()
mbedtls_psa_mac_sign_setup()