gsasl_md5(3)

πŸ“¦ version 1.10.0, in ubuntu jammy

πŸ’… gsasl_md5 β€” the tea β˜•

okay bestie, welcome to the gsasl manual page for gsasl_md5(3). yes that's the section-3 one, the library-call one, not some command you run in your shell. sit down, hydrate, we're doing hashing. πŸ¦‹


✨ NAME ✨

gsasl_md5 β€” it's an API function, periodt. that's the whole vibe.


πŸŽ€ SYNOPSIS πŸŽ€

here's the summoning ritual:

#include <gsasl.h>

int gsasl_md5(const char * in, size_t inlen, char * [] out);

like. look at it. it's giving "small function, big responsibilities". πŸ”₯


🌸 ARGUMENTS 🌸

okay so here's what you're feeding it, one by one:

  • const char * in β€” the input character array, aka the data you wanna hash. it's const so no, you cannot touch it, hands off πŸ’…
  • size_t inlen β€” the length of that input character array of data to hash. yes you have to tell it how long your stuff is, it does not read minds.
  • char * [] out β€” a newly allocated 16-byte character array holding the hash of the data. brand new. fresh out the box. yours to deal with. πŸŽ€

🧚 DESCRIPTION 🧚

so what does it actually do? it computes the hash of your data using MD5. that's it. that's the function. ✨

and listen β€” the out buffer must be deallocated by the caller. that means you, bestie. not the function. it hands you the keys and walks away. don't leak it, it's not the vibe. 😭

Return value: Returns GSASL_OK iff successful. that's it, that's the win condition. anything else and, uh, it wasn't successful. πŸ‘‘

πŸ’€ DEPRECATED πŸ’€

not me having to tell you this... but:

Use a crypto library.

like, fr fr. it's deprecated. it said what it said. go use a crypto library. this one is the "we have MD5 at home" of APIs. 🫢


πŸ› REPORTING BUGS πŸ›

found something cursed? don't suffer in silence, tell the maintainers:

be specific, be kind, include the details. that's the group-chat etiquette. πŸ’–


Copyright Β© 2002-2021 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.

(iconic of them honestly. no royalty, just vibes. slay.)


🌈 SEE ALSO 🌈

The full documentation for gsasl is maintained as a Texinfo manual. If the info and gsasl programs are properly installed at your site, the command

info gsasl

should give you access to the complete manual. As an alternative you may obtain the manual from:

http://www.gnu.org/software/gsasl/manual/

like, go read the whole thing, it's giving comprehensive. πŸ“š


and that's the page, bestie!! this was gsasl 1.10.0, dated with the gsasl_md5(3) page in the gsasl manual. now go deallocate that buffer. i'm literally watching you. πŸ‘€πŸ’œ

πŸ“¦ where this page comes from