int mbedtls_cipher_cmac_starts(mbedtls_cipher_context_t *ctx, const unsigned char *key, size_t keybits)
Set the CMAC key and prepare to authenticate the input data.
CMAC context structure - Contains internal state information only.
unsigned char state[MBEDTLS_CIPHER_BLKSIZE_MAX]
Internal state of the CMAC algorithm.
unsigned char unprocessed_block[MBEDTLS_CIPHER_BLKSIZE_MAX]
Unprocessed data - either data that was not block aligned and is still pending to be processed...
int mbedtls_cipher_cmac(const mbedtls_cipher_info_t *cipher_info, const unsigned char *key, size_t keylen, const unsigned char *input, size_t ilen, unsigned char *output)
Output = Generic_CMAC( hmac key, input buffer )
size_t unprocessed_len
Length of data pending to be processed.
int mbedtls_cipher_cmac_update(mbedtls_cipher_context_t *ctx, const unsigned char *input, size_t ilen)
Generic CMAC process buffer.