gnutls_x509_ext_print(3)
gnutls_x509_ext_print(3) π
okay so bestie, welcome to the gnutls manual β yes, that gnutls, the TLS library that's literally holding the internet's handbag. this page is about gnutls_x509_ext_print, and ngl it's one of the cuter ones because it justβ¦ makes X.509 certificate extensions look pretty for humans. <sparkle>no cap</sparkle>. let's go π¦
πΈ NAME πΈ
gnutls_x509_ext_print β API function β¨ (yes that's literally the whole name section, she's brief but she's iconic)
π SYNOPSIS π
#include <gnutls/x509.h>
int gnutls_x509_ext_print(gnutls_x509_ext_st * exts, unsigned int
exts_size, gnutls_certificate_print_formats_t format, gnutls_datum_t *
out);
like. look at her. four args, one int return, zero drama π
π«Ά ARGUMENTS π«Ά
gnutls_x509_ext_st * extsβ the data to be printed. that's the extension(s) you're serving up for the makeover, bestie.unsigned int exts_sizeβ the number of available structures. i.e. how manygnutls_x509_ext_stcuties you're actually handing over. don't lie about the count, she WILL count them πgnutls_certificate_print_formats_t formatβ indicate the format to use. yes queen, you get to pick the aesthetic. β¨gnutls_datum_t * outβ newly allocated datum with null terminated string. she mallocs it for you (a whole gift π) and it comes null-terminated, so you can just print it. but you are the one who has to free it, we'll get to that.
π DESCRIPTION π
so, the vibe: this function will pretty print X.509 certificate extensions, suitable for display to a human. that's it. that's the job. she takes raw extension bytes and turns them into something your eyeballs can actually read without crying. it's giving translator, it's giving glow-up, it's giving "i got you boo". π
β οΈ IMPORTANT BESTIE β οΈ the outputoutneeds to be deallocated usinggnutls_free(). notfree(), notdelete, not vibes βgnutls_free(). it's hers, she made it, give it back properly or that's a memory leak and we don't do those π«π
β RETURNS β
on success, GNUTLS_E_SUCCESS (0) is returned β slay, we ate, zero notes π otherwise it returns a negative error value, which is gnutls-speak for "something went sideways, check it before you keep going." always check, bestie. always. π
π REPORTING BUGS π
found something cursed? report bugs to <bugs@gnutls.org>. they want to hear it fr fr.
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. (translation: use it, share 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 β the Texinfo manual is the main character, this manpage is just her supportive bestie π§
that's the whole thing, babe. go forth and pretty-print those extensions, and remember: gnutls_free() it after. periodt. π
β¨
gnutls 3.8.13 β signing off from the gnutls_x509_ext_print(3) page, 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