22#ifndef CRACEN_SW_AES_GCM_H
23#define CRACEN_SW_AES_GCM_H
25#include <psa/crypto.h>
26#include <psa/crypto_values.h>
45 const psa_key_attributes_t *attributes,
46 const uint8_t *key_buffer,
size_t key_buffer_size,
63 const psa_key_attributes_t *attributes,
64 const uint8_t *key_buffer,
size_t key_buffer_size,
92 size_t plaintext_length);
105 size_t input_length);
121 size_t input_length, uint8_t *output,
size_t output_size,
122 size_t *output_length);
140 size_t ciphertext_size,
size_t *ciphertext_length,
141 uint8_t *tag,
size_t tag_size,
size_t *tag_length);
158 size_t plaintext_size,
size_t *plaintext_length,
159 const uint8_t *tag,
size_t tag_length);
int32_t psa_status_t
Definition error.h:26
psa_status_t cracen_sw_aes_gcm_set_lengths(cracen_aead_operation_t *operation, size_t ad_length, size_t plaintext_length)
Set lengths for the software AES-GCM operation.
psa_status_t cracen_sw_aes_gcm_abort(cracen_aead_operation_t *operation)
Abort the software AES-GCM operation.
psa_status_t cracen_sw_aes_gcm_set_nonce(cracen_aead_operation_t *operation, const uint8_t *nonce, size_t nonce_length)
Set nonce for the software AES-GCM operation.
psa_status_t cracen_sw_aes_gcm_decrypt_setup(cracen_aead_operation_t *operation, const psa_key_attributes_t *attributes, const uint8_t *key_buffer, size_t key_buffer_size, psa_algorithm_t alg)
Set up the software AES-GCM decryption operation.
psa_status_t cracen_sw_aes_gcm_update_ad(cracen_aead_operation_t *operation, const uint8_t *input, size_t input_length)
Update the software AES-GCM operation with additional data.
psa_status_t cracen_sw_aes_gcm_update(cracen_aead_operation_t *operation, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length)
Update the software AES-GCM operation with new data.
psa_status_t cracen_sw_aes_gcm_finish(cracen_aead_operation_t *operation, uint8_t *ciphertext, size_t ciphertext_size, size_t *ciphertext_length, uint8_t *tag, size_t tag_size, size_t *tag_length)
Finish the software AES-GCM encryption operation.
psa_status_t cracen_sw_aes_gcm_verify(cracen_aead_operation_t *operation, uint8_t *plaintext, size_t plaintext_size, size_t *plaintext_length, const uint8_t *tag, size_t tag_length)
Verify the tag and finish the software AES-GCM decryption operation.
psa_status_t cracen_sw_aes_gcm_encrypt_setup(cracen_aead_operation_t *operation, const psa_key_attributes_t *attributes, const uint8_t *key_buffer, size_t key_buffer_size, psa_algorithm_t alg)
Set up the software AES-GCM encryption operation.
Definition cracen_psa_primitives.h:344