shishi_crc(3)
π shishi_crc β bestie edition π
okay so this is a page from the shishi manual (that's the GNU Shishi Kerberos-ish library, iykyk), section 3, and it's literally just one function. it's giving "small but mighty" energy. let's get into it π«Ά
β¨ NAME β¨
shishi_crc β it's an API function, bestie. that's the whole name. iconic of it.
πΈ SYNOPSIS πΈ
#include <shishi.h>
int shishi_crc(Shishi * handle, const char * in, size_t inlen, char *
out[4]);
look at that signature. chef's kiss. π
π¦ ARGUMENTS π¦
Shishi * handleβ your shishi handle, the one you got fromshishi_init(). it's the whole personality of the call, you can't skip it.const char * inβ the input character array, aka the data you wanna checksum. the vibes you're hashing, basically.size_t inlenβ how long that input character array is. the length. the size. the amount of data. you get it. πchar * out[4]β a freshly allocated character array that'll hold the checksum of your data. she's new, she's yours, you own her now.
π DESCRIPTION π
so the whole thing: it computes the checksum of your data using CRC32 modified according to RFC 1510. and heads up, bestie, the out buffer must be deallocated by the caller β that's a you problem, not a library problem. don't leave her hanging. π«Ά
now the tea on the modifications: compared to standard CRC32, this version does no initial and final XOR, and the output comes back in LSB-first order. that's the whole difference. slay. β¨
β RETURN VALUE β
returns SHISHI_OK iff it succeeded. that's it. if it's not SHISHI_OK, something went sideways. periodt.
π REPORTING BUGS π
found a bug? not me gatekeeping β go tell the devs:
- report bugs to
<bug-shishi@gnu.org> - GNU Shishi home page:
http://www.gnu.org/software/shishi/ - general help using GNU software:
http://www.gnu.org/gethelp/
they wanna hear from you fr fr. π
π COPYRIGHT π
Copyright Β© 2002-2022 Simon Josefsson.
Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved.
(so like... you can copy it. just keep the notice. that's the deal. we love a permissive license moment. π)
π§ SEE ALSO π§
the full documentation for shishi is maintained as a Texinfo manual. if the info and shishi programs are properly installed at your site, the command
info shishi
should give you access to the complete manual. go read it, bestie, it's the main character of the docs. π
that's the whole page!! π written for shishi 1.0.3, and this lil cutie lives at shishi_crc(3) in the manual. mwah, go checksum something. π
β¨
π¦ where this page comes from
- debian bookworm: shishi-doc 1.0.3-1 Β· GPL-3.0-or-later
- debian trixie: shishi-doc 1.0.3-5 Β· GPL-3.0-or-later
- nixos 26.05: shishi 1.0.3
- nixpkgs unstable: shishi 1.0.3
- ubuntu noble: shishi-doc 1.0.3-2.1build2 Β· GPL-3.0-or-later
- ubuntu questing: shishi-doc 1.0.3-5
- ubuntu resolute: shishi-doc 1.0.3-5build1 Β· GPL-3.0-or-later
- ubuntu stonking: shishi-doc 1.0.3-7 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms