KCAPI_MD_HMAC_SHA224(3)

✨ NAME ✨

okay bestie, welcome to kcapi_md_hmac_sha224 β€” it's the HMAC SHA-224 keyed message digest that does the whole thing on one single buffer πŸŽ€ like, one shot, no drama, no multiple calls, we love a convenience queen πŸ’…

This page lives in section 3 of the libkcapi manual, and iykyk πŸ¦‹


🌸 SYNOPSIS 🌸

ssize_t kcapi_md_hmac_sha224(const uint8_t * key, uint32_t keylen,
                             const uint8_t * in, size_t inlen,
                             uint8_t * out, size_t outlen);

that's the whole vibe, literally one function call and ur done ✨


🫢 ARGUMENTS 🫢

  • key β€” [in] the buffer holding ur HMAC key πŸ”‘
  • keylen β€” [in] how long that HMAC key buffer is
  • in β€” [in] the buffer with the input data u wanna digest πŸ“₯
  • inlen β€” [in] the length of that input buffer
  • out β€” [out] the buffer where the message digest goes πŸ’–
  • outlen β€” [in] the length of out

πŸ’œ DESCRIPTION πŸ’œ

so here's the tea β˜• β€” this is a one-shot convenience function, which means a keyed message digest of the buffer u handed over just gets generated. that's it. that's the whole job. iconic behavior fr fr πŸ‘‘

⚠️ important bestie: the output buffer is NOT allocated for u. you have to allocate it urself, and it needs to be at least as long as the message digest size for whichever keyed message digest u picked. no skimping on buffer size, ok? 😭

and here's what it gives back:

  • on success, it returns the size of the message digest ✨
  • -EIO β€” the data cannot be obtained πŸ’€
  • -ENOMEM β€” the buffer is too small for the complete message digest, and in that case the buffer gets filled with the truncated message digest

πŸ¦‹ AUTHOR πŸ¦‹

  • Stephan Mueller <smueller@chronox.de> β€” Author. (the main character who wrote this, we stan 🌟)

and that's the page bestie!! this was libkcapi Manual 1.5.0, dated July 2025 β€” shoutout to the libkcapi girlies, go forth and HMAC responsibly πŸ’–βœ¨πŸŒΈπŸ«ΆπŸ’…

πŸ“¦ where this page comes from