gnutls_x509_crq_set_key(3)
β¨ gnutls_x509_crq_set_key(3) β¨
okay bestie, sit down, hydrate, and let me tell you about a lil function from the gnutls manual that is genuinely doing the most with the least. it's called gnutls_x509_crq_set_key, and no cap, it's one of those tiny functions that carries the whole plot. π
πΈ NAME πΈ
gnutls_x509_crq_set_key β and yes it's an API function, it said so itself π
π¦ SYNOPSIS π¦
#include <gnutls/x509.h>
int gnutls_x509_crq_set_key(gnutls_x509_crq_t crq, gnutls_x509_privkey_t
key);
like, that's the whole entrance. two args, one int coming back. iconic behaviour honestly.
π ARGUMENTS π
gnutls_x509_crq_t crqβ this one should contain agnutls_x509_crq_ttype. it's the request, the moment, the main character of this whole operation π«Άgnutls_x509_privkey_t keyβ this lil guy holds a private key. that's it. that's the job. keep it safe bestie π
π DESCRIPTION π
so here's the tea: this function will set the public parameters from the given private key to the request. that's literally the entire vibe. you hand it a cert request and a private key, and it pulls the public parameters off that key and drops them into the request. no drama, no extra steps, just a clean little handoff β¨
β RETURNS β
- On success,
GNUTLS_E_SUCCESS(0) is returned π - otherwise you get a negative error value π
so like, check your return values, bestie, fr fr. zero is the goal. anything negative is the universe telling you something went sideways.
π REPORTING BUGS π
found something cursed? don't suffer in silence, tell the people:
- 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. (slay, honestly β that's the good licensing energy π)
π₯ 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/
and that's the whole page, bestie. this one came from the gnutls manual, version 3.8.13, and it's filed under the gnutls_x509_crq_set_key(3) page β so if you ever need to find it again, that's exactly where it lives. go set some keys. you got this. π
πΈπ¦
π¦ 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