crypto_shash_final(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

🌸 crypto_shash_final(9) β€” the Kernel API Manual, bestie edition 🌸

okay so this is a page from the Kernel API Manual and it's about crypto_shash_final(9), which is literally the "ok we're done, hand me the digest" moment of the synchronous hash world. pull up a chair 🫢


✨ NAME ✨

crypto_shash_final β€” calculate message digest πŸ’…

πŸ¦‹ SYNOPSIS πŸ¦‹

int crypto_shash_final (struct shash_desc *desc , u8 *out );

πŸŽ€ ARGUMENTS πŸŽ€

  • desc β€” the operational state handle, and it's already filled with data. like, the homework is done, this is the turning-it-in part πŸ“š
  • out β€” the output buffer that gets filled with the message digest. it's the little envelope your digest gets yeeted into βœ‰οΈ

πŸ’– DESCRIPTION πŸ’–

so basically you finalize the message digest operation and create the message digest based on all the data added to the cipher handle. the way that this works is the message digest gets placed into the output buffer. periodt.

⚠️ real talk though: the caller must ensure that the output buffer is large enough by using crypto_shash_digestsize. no cap, if you skimp on the buffer that's on you, not on the kernel 😭

πŸ”₯ CONTEXT πŸ”₯

Softirq or process context. that's the vibe check, and it passes βœ…

πŸ‘‘ RETURN πŸ‘‘

  • 0 if the message digest creation was successful β€” slay πŸ’…
  • < 0 if an error occurred β€” πŸ’€

⭐ SEE ALSO ⭐

okay buckle up bestie, this list is long but it's giving comprehensive, so:

iykyk 🌈


and that's the whole page, no notes πŸ’œ this little gem lives in ./include/crypto and it's dated October 2026, filed under crypto_shash_final(9). go forth and finalize your digests, bestie β€” you're gonna eat πŸ“βœ¨

πŸ“¦ where this page comes from