11.12.3.4.234. Function sss_se05x_aead_finish

11.12.3.4.234.1. Function Documentation

sss_status_t sss_se05x_aead_finish(sss_se05x_aead_t *context, const uint8_t *srcData, size_t srcLen, uint8_t *destData, size_t *destLen, uint8_t *tag, size_t *tagLen)

Finalize AEAD. The functions processes data that has not been processed by previous calls to sss_aead_update() as well as srcData. It finalizes the AEAD operations and computes the tag (encryption) or compares the computed tag with the tag supplied in the parameter (decryption).

Return

Status of the operation

Parameters
  • context: Pointer to aead crypto context.

  • srcData: Buffer containing final chunk of input data.

  • srcLen: Length of final chunk of input data in bytes.

  • destData: Buffer containing output data.

  • [inout] destLen: Length of output data in bytes. Buffer length on entry, reflects actual output size on return.

  • tag: Encryption: Output buffer filled with computed tag Decryption: Input buffer filled with received tag

  • tagLen: Length of the computed or received tag in bytes. For AES-GCM it must be 4,8,12,13,14,15 or 16. For AES-CCM it must be 4,6,8,10,12,14 or 16.

Return Value