shishi_kdcreq_realm(3)
β¨ shishi_kdcreq_realm β¨
okay bestie, so this is a page from the shishi manual β section 3, the library-function corner of the world π
. It's called shishi_kdcreq_realm, and it's literally just here to hand you the realm out of a KDC-REQ. Cute, simple, iconic. Let's go π¦
πΈ NAME πΈ
shishi_kdcreq_realm β an API function, no cap.
π SYNOPSIS π
#include <shishi.h>
int shishi_kdcreq_realm(Shishi * handle, Shishi_asn1 kdcreq, char **
realm, size_t * realmlen);
π ARGUMENTS π
Shishi * handleβ the Shishi library handle, the one you got fromshishi_init(). Your whole vibe lives in here.Shishi_asn1 kdcreqβ the KDC-REQ variable you're pulling the client name out of.char ** realmβ a pointer to a freshly allocated, zero-terminated string holding the realm. It's allowed to beNULLβ in which case you're just populatingrealmlenand nothing else, and honestly, valid.size_t * realmlenβ a pointer to the length of the realm on output, and that length does not count the terminating zero. Also may beNULL(to only populaterealmlen) β yes, the original says it that way, and yes, we're keeping it exactly like that, fr fr π.
π«Ά DESCRIPTION π«Ά
So the whole point: grab the realm field inside a KDC-REQ and give it back to you as a zero-terminated string. That's it, that's the function β¨
The string is allocated by this function, and β listen up, this part matters β it is the responsibility of the caller to deallocate it. So you free it. Not us. You. Don't forget, bestie, or that's a leak π
Also, quick note: the output length realmlen does not include the terminating zero. So if it says 5, it's 5 characters plus the little zero at the end. Periodt.
π₯ RETURN VALUE π₯
Returns SHISHI_OK iff successful. That's the whole return value story. Slay.
π REPORTING BUGS π
Found a bug? Don't suffer in silence, tell the people:
- 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/
π 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. (Yes, really β go wild, just keep the receipts π)
π 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. iykyk π§
and that's the page, bestie π
β brought to you by shishi, version 1.0.3, in the shishi_kdcreq_realm(3) era. go forth, get that realm, and free your strings ππ¦β
π¦ 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