kcapi_aead_ccm_nonce_to_iv(3)

convert CCM nonce into IV

Section 3 libkcapi-dev bookworm source

Description

KCAPI_AEAD_CCM_NONCE

NAME

kcapi_aead_ccm_nonce_to_iv - convert CCM nonce into IV

SYNOPSIS

int kcapi_aead_ccm_nonce_to_iv(const uint8_t * nonce, uint32_t noncelen, uint8_t ** iv, uint32_t * ivlen);

ARGUMENTS

nonce

[in] buffer with nonce

noncelen

[in] length of nonce

iv

[out] newly allocated buffer with IV

ivlen

[out] length of IV

DESCRIPTION

This service function converts a CCM nonce value into an IV usable by the kernel crypto API.

Caller must free iv.

return 0 upon success; < 0 upon failure

AUTHOR

Stephan Mueller <smueller@chronox.de>

Author.

COPYRIGHT