2022-10-03 15:39:00 +00:00
|
|
|
#ifndef __AES_H__
|
|
|
|
#define __AES_H__
|
|
|
|
|
|
|
|
#include <stdint.h>
|
|
|
|
|
|
|
|
#define AES_256_KEY_SIZE 32
|
|
|
|
#define AES_IV_SIZE 16
|
2024-02-02 16:57:00 +00:00
|
|
|
#define AES_BLOCK_SIZE 16
|
2022-10-03 15:39:00 +00:00
|
|
|
|
2023-03-10 14:44:21 +00:00
|
|
|
uint8_t aes_encrypt_cbc(const uint8_t* key, const uint8_t* iv, const uint8_t* data, uint32_t len, uint8_t* out);
|
|
|
|
uint8_t aes_decrypt_cbc(const uint8_t* key, const uint8_t* iv, const uint8_t* data, uint32_t len, uint8_t* out);
|
2022-10-03 15:39:00 +00:00
|
|
|
uint8_t aes_cmac(const uint8_t* key, const uint8_t* data, uint32_t len, uint8_t* out);
|
|
|
|
|
2023-03-01 14:25:06 +00:00
|
|
|
#endif
|