custom-tee-storage/bliq_storage/ta/operations.h
2024-03-21 22:12:03 +01:00

28 lines
527 B
C

#include <tee_internal_api.h>
#ifndef OPERATIONS_H
#define OPERATIONS_H
typedef struct {
TEE_OperationHandle hSK_encrypt;
TEE_OperationHandle hSK_decrypt;
} Session;
TEE_Result so_init(
char *pin, size_t pin_sz,
Session *session);
void so_free(
Session *session);
TEE_Result so_encrypt(
Session *session,
void *inbuf, uint32_t inbuf_sz,
void *outbuf, uint32_t *outbuf_sz);
TEE_Result so_decrypt(
Session *session,
void *inbuf, uint32_t inbuf_sz,
void *outbuf, uint32_t *outbuf_sz);
#endif /*OPERATIONS_H*/