CRYPTO_ccm128_decrypt

Decrypt ciphertext and update the CCM authentication state.

Synopsis

Declared in <openssl/modes.h>

int
CRYPTO_ccm128_decrypt(
    CCM128_CONTEXT* ctx,
    unsigned char const* inp,
    unsigned char* out,
    size_t len);

Return Value

1 on success, or 0 on failure.

Parameters

NameDescription
ctxCCM context ready for decryption (nonce and optional AAD set).
inpCiphertext bytes of length len.
outPlaintext buffer of length len.
lenNumber of bytes to decrypt.