gnutls_x509_crt_get_pk_algorithm(3)
π gnutls_x509_crt_get_pk_algorithm β the gnutls manual, bestie edition π
okay so you're reading the gnutls manual page for gnutls_x509_crt_get_pk_algorithm(3) and honestly? iconic choice. let's get into it π
β¨ NAME β¨
gnutls_x509_crt_get_pk_algorithm β it's an API function, bestie. that's the whole name. short, sweet, slays. π
πΈ SYNOPSIS πΈ
#include <gnutls/x509.h>
int gnutls_x509_crt_get_pk_algorithm(gnutls_x509_crt_t cert, unsigned
int * bits);
like yes, she takes two args and returns an int. we love a simple signature, no notes. π¦
π«Ά ARGUMENTS π«Ά
gnutls_x509_crt_t certβ this one should contain agnutls_x509_crt_ttype. that's it, that's the vibe check. she's your certificate, hand her over. πunsigned int * bitsβ ifbitsis non null it's gonna hold the size of the parameters' in bits. so like, a pointer, and if you pass it she fills it in. β¨
π DESCRIPTION π
so what does she actually do? this function will return the public key algorithm of an X.509 certificate. periodt. π₯
and if bits is non null, it should have enough size to hold the parameters size in bits. important, don't skip this: for RSA the bits returned is the modulus. for DSA the bits returned are of the public exponent. different keys, different meanings, no cap. π
unknown/unsupported algorithms are mapped to GNUTLS_PK_UNKNOWN. she doesn't guess, she doesn't improvise β she just says "idk her" and moves on. π
β RETURNS β
on success you get a member of the gnutls_pk_algorithm_t enumeration. π
or, if things went sideways, a negative error code on error. so like, check your return value, bestie, don't just assume. π
π REPORTING BUGS π
found something cursed? report bugs to <bugs@gnutls.org>.
home page: https://www.gnutls.org
they genuinely wanna hear about it, fr fr. π«Ά
π 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 forth and share, she's free πβ¨
π§ 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/
that's your girl, go read her. iykyk. π
and that's the whole page, bestie β gnutls version 3.8.13, this manual page for gnutls_x509_crt_get_pk_algorithm(3), dated with all the love. 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