shishi_as_derive_salt(3)
π shishi_as_derive_salt(3) π
okay bestie, welcome to the shishi manual β this one is shishi_as_derive_salt, an API function, and it's literally the girl who figures out your salt for you. no cap. π§β¨
β¨ SYNOPSIS β¨
#include <shishi.h>
int shishi_as_derive_salt(Shishi * handle, Shishi_asn1 asreq,
Shishi_asn1 asrep, char ** salt, size_t * saltlen);
π«Ά ARGUMENTS π«Ά
Shishi * handleβ the Shishi handle, allocated byshishi_init(). she's the main character, everything runs through her πShishi_asn1 asreqβ Input AS-REQ variable. yes, that's an input, she's giving source material πΈShishi_asn1 asrepβ Input AS-REP variable. also an input, also iconic π¦char ** saltβ Returned pointer to a newly allocated output array. brand new, freshly allocated, no reusing πsize_t * saltlenβ Pointer to integer, returning size of output array. she tells you how big the vibe is π
π DESCRIPTION π
so basically, this function computes the salt that should be used when deriving a key via shishi_string_to_key() for an AS exchange. it's giving key-derivation-prep energy, fr fr.
the way it works rn: it searches for PA-DATA of type SHISHI_PA_PW_SALT in the AS-REP provided by asrep, and if present, returns it. periodt. that's the first path.
otherwise β and this is the backup plan, lowkey the plot twist β the salt is composed from the client name and the realm, and both of those are extracted from the request asreq. so either the AS-REP hands you a salt, or you build one yourself from the request. obsessed with the flexibility honestly π
β RETURN VALUE β
Returns SHISHI_OK if successful. π
failure conditions include various ASN.1 issues β like, if the ASN.1 is not ASN.1-ing, that's a fail. no guessing beyond that bestie, that's what the page says π
π REPORTING BUGS π
found a bug? don't be shy, report it 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. (so yes, you can share it, 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 ππ
not me writing a whole manual page just so you'd understand salt derivation... but also, you're welcome bestie π«Ά
and that's the whole thing!! this page is from shishi 1.0.3, and it lives under the shishi manual β mwah, go slay your AS exchange π
ππ
π¦ 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