nrfxlib API 0.1.0
Loading...
Searching...
No Matches

◆ ocrypto_aes_gcm_encrypt()

void ocrypto_aes_gcm_encrypt ( uint8_t *  ct,
uint8_t *  tag,
size_t  tag_len,
const uint8_t *  pt,
size_t  pt_len,
const uint8_t *  key,
size_t  size,
const uint8_t  iv[12],
const uint8_t *  aa,
size_t  aa_len 
)

#include <crypto/nrf_oberon/include/ocrypto_aes_gcm.h>

AES-GCM encryption.

Parameters
[out]ctCiphertext.
[out]tagAuthentication tag.
tag_lenAuthentication tag length, 0 < tag_len <= 16.
ptPlaintext.
pt_lenPlaintext length, 0 < ct_len < 2^36-32 bytes.
keyAES key.
sizeKey size (16, 24, or 32 bytes).
ivInitial vector.
aaAdditional authentication data.
aa_lenAdditional authentication data length, 0 < aa_len < 2^61 bytes.
Remarks
ct may be same as pt.