cnstr_shdsc_chachapoly(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… cnstr_shdsc_chachapoly β€” kernel API manual, bestie edition πŸŽ€

okay so real talk, this is a 9 section page from the Kernel API Manual, and the star of the show is cnstr_shdsc_chachapoly. It builds you a shared descriptor for Chacha20 + Poly1305 generic AEAD (that's rfc7539, iykyk) and for IPsec ESP (that's rfc7634, a.k.a. rfc7539esp). Non-protocol, bestie. It's giving "I just make the descriptor, you take it from here." ✨


🌸 NAME 🌸

cnstr_shdsc_chachapoly β€” the Chacha20 + Poly1305 generic AEAD (rfc7539) and IPsec ESP (rfc7634, a.k.a. rfc7539esp) shared descriptor builder (non-protocol). literally her whole job πŸ’–


✨ SYNOPSIS ✨

void cnstr_shdsc_chachapoly (u32 * const desc , struct alginfo *cdata ,
struct alginfo *adata , unsigned int ivsize , unsigned int icvsize ,
const bool encap , const bool is_qi );

no return value, she just goes off and does the thing 🫢


πŸ¦‹ ARGUMENTS πŸ¦‹

  • desc β€” pointer to the buffer you're using for descriptor construction. this is where the magic gets written, so pls have it ready πŸ’…
  • cdata β€” pointer to the block cipher transform definitions. valid algorithm values are OP_ALG_ALGSEL_CHACHA20 ANDed with OP_ALG_AAI_AEAD. that's the combo, no substitutions πŸŽ€
  • adata β€” pointer to the authentication transform definitions. valid algorithm values are OP_ALG_ALGSEL_POLY1305 ANDed with OP_ALG_AAI_AEAD. same deal, ANDed and iconic ⭐
  • ivsize β€” initialization vector size πŸ‘‘
  • icvsize β€” integrity check value (ICV) size, and yes it can be truncated or full, your call πŸ’€
  • encap β€” true if encapsulation, false if decapsulation. pick a lane bestie 🌈
  • is_qi β€” true when called from caam/qi 🌸

πŸ”₯ SEE ALSO πŸ”₯

kernel file ./drivers/crypto/caam/caamalg_desc.c β€” like, go read her, she's the source fr fr

and the whole friend group, no cap:


heads up bestie: the algorithm values are strict. OP_ALG_ALGSEL_CHACHA20 ANDed with OP_ALG_AAI_AEAD for cdata, and OP_ALG_ALGSEL_POLY1305 ANDed with OP_ALG_AAI_AEAD for adata. don't freestyle, she will not slay πŸ™ˆ

and that's the whole page, mwah πŸ’‹ this icon lives in ./drivers/crypto/caam and this particular printing is the October 2026 edition of cnstr_shdsc_chachapoly(9). go build some descriptors, bestie, you got this πŸ§šπŸ’œ

πŸ“¦ where this page comes from