12#ifndef __T_COSE_UTIL_H__
13#define __T_COSE_UTIL_H__
92#define T_COSE_SHORT_CIRCUIT_KID_SIZE 32
UsefulBufC and UsefulBuf are simple data structures to hold a pointer and length for a binary data.
The non-const UsefulBuf typically used for some allocated memory that is to be filled in.
Defines common to all public t_cose interfaces.
t_cose_err_t
Error codes return by t_cose.
enum t_cose_err_t get_short_circuit_kid(struct useful_buf buffer_for_kid, struct useful_buf_c *kid)
Get the special kid for short-circuit signing.
int32_t hash_alg_id_from_sig_alg_id(int32_t cose_sig_alg_id)
Return hash algorithm ID from a signature algorithm ID.
enum t_cose_err_t create_tbs_hash(int32_t cose_alg_id, struct useful_buf buffer_for_hash, struct useful_buf_c *hash, struct useful_buf_c protected_headers, struct useful_buf_c payload)
Create the hash of the to-be-signed (TBS) bytes for COSE.
This is a TF-M coding style version of UsefulBuf.