74#ifndef __TC_CCM_MODE_H__
75#define __TC_CCM_MODE_H__
85#define TC_CCM_AAD_MAX_BYTES 0xff00
88#define TC_CCM_PAYLOAD_MAX_BYTES 0x10000
91typedef struct tc_ccm_mode_struct {
92 TCAesKeySched_t sched;
111int tc_ccm_config(TCCcmMode_t c, TCAesKeySched_t sched, uint8_t *nonce,
112 unsigned int nlen,
unsigned int mlen);
157 const uint8_t *associated_data,
158 unsigned int alen,
const uint8_t *payload,
159 unsigned int plen, TCCcmMode_t c);
203 const uint8_t *associated_data,
204 unsigned int alen,
const uint8_t *payload,
unsigned int plen,
– Interface to an AES-128 implementation.
int tc_ccm_decryption_verification(uint8_t *out, unsigned int olen, const uint8_t *associated_data, unsigned int alen, const uint8_t *payload, unsigned int plen, TCCcmMode_t c)
CCM decryption and tag verification procedure.
Definition ccm_mode.c:198
int tc_ccm_config(TCCcmMode_t c, TCAesKeySched_t sched, uint8_t *nonce, unsigned int nlen, unsigned int mlen)
CCM configuration procedure.
Definition ccm_mode.c:39
int tc_ccm_generation_encryption(uint8_t *out, unsigned int olen, const uint8_t *associated_data, unsigned int alen, const uint8_t *payload, unsigned int plen, TCCcmMode_t c)
CCM tag generation and encryption procedure.
Definition ccm_mode.c:137