gnutls_pkcs12_export2(3)
π gnutls_pkcs12_export2(3) β the gnutls manual, bestie edition π
okay so you're here for gnutls_pkcs12_export2, a function in the gnutls manual, and honestly? she's a whole vibe. let's get into it π
β¨ NAME β¨
gnutls_pkcs12_export2 β API function. yes bestie, that's the whole name, she's lowkey mysterious like that π
πΈ SYNOPSIS πΈ
#include <gnutls/pkcs12.h>
int gnutls_pkcs12_export2(gnutls_pkcs12_t pkcs12, gnutls_x509_crt_fmt_t
format, gnutls_datum_t * out);
π¦ ARGUMENTS π¦
gnutls_pkcs12_t pkcs12β a pkcs12 type, aka the little bundle of joy you're about to yeet out into the world β¨gnutls_x509_crt_fmt_t formatβ the format of the output params. it's giving one of PEM or DER, pick your fighter, no in-between π«Άgnutls_datum_t * outβ will contain a structure PEM or DER encoded. this is where the goods land, bestie π¦
π DESCRIPTION π
so basically: this function will export the pkcs12 structure to DER or PEM format. that's it, that's the job, and she does it flawlessly, periodt π
The output buffer is allocated using gnutls_malloc(). noting this fr fr β so you're gonna want to free it properly when you're done, iykyk.
If the structure is PEM encoded, it will have a header of "BEGIN PKCS12". iconic header, no cap π
β RETURNS β
In case of failure a negative error code will be returned, and 0 on success. so like β negative means π, zero means π₯³. check it every time, don't be messy.
π SINCE π
3.1.3 β she's been around a minute, a true veteran of the codebase π
π REPORTING BUGS π
found something cursed? Report bugs to <bugs@gnutls.org>. don't suffer in silence bestie, tell the devs π«Ά
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. slay, that's the license, keep the receipt π
π 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/
like genuinely go read it, it's the main character of documentation π§
reminder bestie: the buffer comes from gnutls_malloc(), so treat it like the precious thing it is and free it when you're done. no leaks in this household π
and that's the whole page!! this came from the gnutls manual, version 3.8.13, and the page itself is gnutls_pkcs12_export2(3). ty for reading my little info dump, go export something gorgeous ππ
π¦ 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