Files | |
file | psa_ciphers.h |
Function declarations for low level wrapper functions for cipher operations. | |
Functions | |
psa_status_t | psa_cipher_cbc_aes_128_encrypt (const psa_key_attributes_t *attributes, const uint8_t *key_buffer, size_t key_buffer_size, psa_algorithm_t alg, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length) |
Low level wrapper function to call a driver for an AES 128 CBC encryption. | |
psa_status_t | psa_cipher_cbc_aes_128_decrypt (const psa_key_attributes_t *attributes, const uint8_t *key_buffer, size_t key_buffer_size, psa_algorithm_t alg, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length) |
Low level wrapper function to call a driver for an AES 128 CBC decryption. | |
psa_status_t | psa_cipher_cbc_aes_192_encrypt (const psa_key_attributes_t *attributes, const uint8_t *key_buffer, size_t key_buffer_size, psa_algorithm_t alg, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length) |
Low level wrapper function to call a driver for an AES 192 CBC encryption. | |
psa_status_t | psa_cipher_cbc_aes_256_encrypt (const psa_key_attributes_t *attributes, const uint8_t *key_buffer, size_t key_buffer_size, psa_algorithm_t alg, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length) |
Low level wrapper function to call a driver for an AES 256 CBC encryption. | |
psa_status_t | psa_cipher_chacha20_encrypt (uint8_t *key_buffer, size_t key_buffer_size, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length) |
Low level wrapper function to call a driver for ChaCha20 encryption/decryption. | |
psa_status_t | psa_cipher_chacha20_decrypt (uint8_t *key_buffer, size_t key_buffer_size, const uint8_t *input, size_t input_length, uint8_t *output, size_t output_size, size_t *output_length) |
Low level wrapper function to call a driver for ChaCha20 decryption. | |
psa_status_t psa_cipher_cbc_aes_128_decrypt | ( | const psa_key_attributes_t * | attributes, |
const uint8_t * | key_buffer, | ||
size_t | key_buffer_size, | ||
psa_algorithm_t | alg, | ||
const uint8_t * | input, | ||
size_t | input_length, | ||
uint8_t * | output, | ||
size_t | output_size, | ||
size_t * | output_length | ||
) |
Low level wrapper function to call a driver for an AES 128 CBC decryption.
attributes | |
key_buffer | |
key_buffer_size | |
alg | |
input | |
input_length | |
output | |
output_size | |
output_length |
psa_status_t psa_cipher_cbc_aes_128_encrypt | ( | const psa_key_attributes_t * | attributes, |
const uint8_t * | key_buffer, | ||
size_t | key_buffer_size, | ||
psa_algorithm_t | alg, | ||
const uint8_t * | input, | ||
size_t | input_length, | ||
uint8_t * | output, | ||
size_t | output_size, | ||
size_t * | output_length | ||
) |
Low level wrapper function to call a driver for an AES 128 CBC encryption.
attributes | |
key_buffer | |
key_buffer_size | |
alg | |
input | |
input_length | |
output | |
output_size | |
output_length |
psa_status_t psa_cipher_cbc_aes_192_encrypt | ( | const psa_key_attributes_t * | attributes, |
const uint8_t * | key_buffer, | ||
size_t | key_buffer_size, | ||
psa_algorithm_t | alg, | ||
const uint8_t * | input, | ||
size_t | input_length, | ||
uint8_t * | output, | ||
size_t | output_size, | ||
size_t * | output_length | ||
) |
Low level wrapper function to call a driver for an AES 192 CBC encryption.
attributes | |
key_buffer | |
key_buffer_size | |
alg | |
input | |
input_length | |
output | |
output_size | |
output_length |
psa_status_t psa_cipher_cbc_aes_256_encrypt | ( | const psa_key_attributes_t * | attributes, |
const uint8_t * | key_buffer, | ||
size_t | key_buffer_size, | ||
psa_algorithm_t | alg, | ||
const uint8_t * | input, | ||
size_t | input_length, | ||
uint8_t * | output, | ||
size_t | output_size, | ||
size_t * | output_length | ||
) |
Low level wrapper function to call a driver for an AES 256 CBC encryption.
attributes | |
key_buffer | |
key_buffer_size | |
alg | |
input | |
input_length | |
output | |
output_size | |
output_length |
psa_status_t psa_cipher_chacha20_decrypt | ( | uint8_t * | key_buffer, |
size_t | key_buffer_size, | ||
const uint8_t * | input, | ||
size_t | input_length, | ||
uint8_t * | output, | ||
size_t | output_size, | ||
size_t * | output_length | ||
) |
Low level wrapper function to call a driver for ChaCha20 decryption.
See psa_cipher_decrypt().
key_buffer | Buffer containing the Key. |
key_buffer_size | Size of the key in bytes. Must be 32 bytes long. |
input | Input buffer containing the 12 byte nonce used in the encryption followed by the cipher to be decrypted. |
input_length | Size of input buffer (including 12 byte nonce). |
output | Output buffer. |
output_size | Size of output buffer. Must be at least (input_length - 12) bytes long. |
output_length | Actual size of the output. |
psa_status_t psa_cipher_chacha20_encrypt | ( | uint8_t * | key_buffer, |
size_t | key_buffer_size, | ||
const uint8_t * | input, | ||
size_t | input_length, | ||
uint8_t * | output, | ||
size_t | output_size, | ||
size_t * | output_length | ||
) |
Low level wrapper function to call a driver for ChaCha20 encryption/decryption.
See psa_cipher_encrypt().
key_buffer | Buffer containing the Key. |
key_buffer_size | Size of the key in bytes. Must be 32 bytes. |
input | Input Buffer containing the message to be encrypted. |
input_length | Size of input buffer. |
output | Output buffer containing the generated 12 byte nonce followed by the cipher of the input. |
output_size | Size of output buffer. Must be at least (input_length + 12) bytes long. |
output_length | Actual size of the output (including nonce). |