gnutls_x509_crq_get_key_id(3)
π gnutls_x509_crq_get_key_id π
okay bestie, so this one lives in the gnutls manual, section 3, and it's literally the glow-up your certificate request needed. it's gnutls_x509_crq_get_key_id and it's giving "who even are you" but in a β¨cryptographicβ¨ way.
β¨ SYNOPSIS β¨
#include <gnutls/x509.h>
int gnutls_x509_crq_get_key_id(gnutls_x509_crq_t crq, unsigned int
flags, unsigned char * output_data, size_t * output_data_size);
no cap, that's the whole vibe right there. π«Ά
πΈ ARGUMENTS πΈ
gnutls_x509_crq_t crqβ a certificate of typegnutls_x509_crq_t. yes she's the main character, we love her.unsigned int flagsβ should be one of the flags fromgnutls_keyid_flags_t. pick your fighter wisely, bestie.unsigned char * output_dataβ this is where the key ID is gonna live. it will contain the key ID πsize_t * output_data_sizeβ holds the size ofoutput_data, and heads up, it will be replaced by the actual size of parameters. she's not just a reader, she's a writer too.
π¦ DESCRIPTION π¦
so what does this function actually do, you ask? it returns a unique ID that depends on the public key parameters. iconic. that ID can be used in checking whether a certificate corresponds to the given private key. like a little fingerprint but for vibes. π₯
now listen, the important part: if the buffer you provided is not long enough to hold the output, then * output_data_size is updated and GNUTLS_E_SHORT_MEMORY_BUFFER will be returned. so she's not ghosting you, she's telling you exactly how much room she needs. π
the output will normally be a SHA-1 hash output, which is 20 bytes. yes, twenty. count them.
β RETURNS β
in case of failure a negative error code will be returned, and 0 on success. so like, zero is the good one here. don't panic when you see it. periodt.
π SINCE π
2.8.0 β she's been around, she's a legend, she's been slaying since way back.
π REPORTING BUGS π
found a bug? don't be shy, tell the girlies:
- report bugs to
<bugs@gnutls.org> - home page:
https://www.gnutls.org
π COPYRIGHT π
Copyright Β© 2001-2023 Free Software Foundation, Inc., and others.
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 go off, share it, remix it, just keep the receipts. π
π SEE ALSO π
the full documentation for gnutls is maintained as a Texinfo manual. if the /usr/share/doc/gnutls/ directory does not contain the HTML form, visit:
https://www.gnutls.org/manual/
iykyk. go read the full thing, it's a whole saga. π§
okay that's the whole page, bestie. every flag, every byte, every legal line β all still here, just with better energy. π
and that's a wrap on the gnutls 3.8.13 version of this page, from the gnutls_x509_crq_get_key_id(3) manual. mwah. πβ¨
π¦ where this page comes from
- alpine 3.22: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- alpine 3.23: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- alpine 3.24: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- arch rolling: gnutls 3.8.13-3 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: gnutls-devel 3.8.13-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: gnutls-devel 3.8.13-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: gnutls-devel 3.8.13-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: gnutls-devel 3.8.13-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- ubuntu stonking: gnutls-doc 3.8.13-1ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms