CRYPTO_ccm128_tag

Write the computed CCM authentication tag into tag.

Synopsis

Declared in <openssl/modes.h>

size_t
CRYPTO_ccm128_tag(
    CCM128_CONTEXT* ctx,
    unsigned char* tag,
    size_t len);

Return Value

Number of tag bytes written (len), or 0 if len does not match M.

Parameters

NameDescription
ctxCCM context after encryption (and optional AAD) processing.
tagDestination buffer for the tag; len must equal the configured M tag length.
lenNumber of tag bytes requested (must match the M value from CRYPTO_ccm128_init()).