cnstr_shdsc_aead_givencap(9)
π cnstr_shdsc_aead_givencap π
okay so bestie, welcome to the Kernel API Manual entry for cnstr_shdsc_aead_givencap β literally the function that builds you an IPSec ESP encapsulation shared descriptor (non-protocol flavoured β¨) with a HW-generated initialization vector. no cap, that's the whole NAME section, she's lowkey iconic.
β¨ SYNOPSIS β¨
void cnstr_shdsc_aead_givencap (u32 * const desc , struct alginfo *cdata
, struct alginfo *adata , unsigned int ivsize , unsigned int icvsize ,
const bool is_rfc3686 , u32 *nonce , const u32 ctx1_iv_off , const bool
is_qi , int era );
void, bestie. she returns nothing. she just builds. main character energy fr fr π«Ά
π ARGUMENTS π
descβ pointer to the buffer used for descriptor construction. this is where the magic gets written, she's the canvas πcdataβ pointer to block cipher transform definitions. valid algorithm values are one ofOP_ALG_ALGSEL_{AES, DES, 3DES}ANDed withOP_ALG_AAI_CBCorOP_ALG_AAI_CTR_MOD128. that's the whole list, don't come for me πΈadataβ pointer to authentication transform definitions. heads up queen: a split key is required for SEC Era < 6, and in that case the size of the split key is specified here. valid algorithm values are one ofOP_ALG_ALGSEL_{MD5, SHA1, SHA224, SHA256, SHA384, SHA512}ANDed withOP_ALG_AAI_HMAC_PRECOMP. slay πivsizeβ initialization vector size. literally the size of the IV π¦icvsizeβ integrity check value (ICV) size, and yes it can be truncated or full, your call β¨is_rfc3686βtruewhenctr(aes)is wrapped by the rfc3686 template. a little bool doing a big job πnonceβ pointer to the rfc3686 nonce πctx1_iv_offβ IV offset in the CONTEXT1 register. it'sconst u32, so don't even think about it π₯is_qiβtruewhen called fromcaam/qiβeraβ SEC Era. just... the era. know your era bestie π
π SEE ALSO π
the kernel file she lives in:
./drivers/crypto/caam/caamalg_desc.c
and her whole friend group, all iconics, all (9):
cnstr_shdsc_aead_null_encap(9)cnstr_shdsc_aead_null_decap(9)cnstr_shdsc_aead_encap(9)cnstr_shdsc_aead_decap(9)cnstr_shdsc_gcm_encap(9)cnstr_shdsc_gcm_decap(9)cnstr_shdsc_rfc4106_encap(9)cnstr_shdsc_rfc4106_decap(9)cnstr_shdsc_rfc4543_encap(9)cnstr_shdsc_rfc4543_decap(9)cnstr_shdsc_chachapoly(9)cnstr_shdsc_skcipher_encap(9)cnstr_shdsc_skcipher_decap(9)cnstr_shdsc_xts_skcipher_encap(9)cnstr_shdsc_xts_skcipher_decap(9)
go read them. iykyk π
okay that's the whole page, mwah π β signed off from ./drivers/crypto/caam, dated October 2026, and the queen herself is cnstr_shdsc_aead_givencap(9). periodt π§ββοΈπ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms