gnutls_dh_params_import_raw2(3)
π gnutls_dh_params_import_raw2(3) π
okay bestie, sit down, hydrate, and let me tell you about a lil function from the gnutls manual π
this one's called gnutls_dh_params_import_raw2 and it's genuinely so useful, no cap.
β¨ NAME β¨
gnutls_dh_params_import_raw2 β API function π
πΈ SYNOPSIS πΈ
#include <gnutls/gnutls.h>
int gnutls_dh_params_import_raw2(gnutls_dh_params_t dh_params, const
gnutls_datum_t * prime, const gnutls_datum_t * generator, unsigned
key_bits);
π¦ ARGUMENTS π¦
gnutls_dh_params_t dh_paramsβ the parameters, aka the lil container we're about to fill with fresh vibes β¨const gnutls_datum_t * primeβ holds the new prime π’const gnutls_datum_t * generatorβ holds the new generator π±unsigned key_bitsβ the private key bits (set to zero when unknown) π
π DESCRIPTION π
This function will replace the pair of prime and generator for use in the Diffie-Hellman key exchange. πβ¨ The new parameters should be stored in the appropriate gnutls_datum.
that's it, that's the whole thing β it swaps out your old prime + generator duo for a shiny new one and drops it right into your gnutls_datum. main character energy fr fr π
π RETURNS π
On success, GNUTLS_E_SUCCESS (0) is returned π₯³ otherwise a negative error code is returned π (yes, negative. it's giving "something went wrong bestie", check that code).
π REPORTING BUGS π
Report bugs to <bugs@gnutls.org>. Home page: https://www.gnutls.org
not me begging you to actually report the bugs instead of just suffering in silence π they wanna hear from you, for real.
π 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.
π«Ά 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, you ate it π
β¨ the full docs live in the gnutls manual, version 3.8.13, and this lil writeup is filed under gnutls_dh_params_import_raw2(3) β go forth and import those params, you iconic legend ππ
π¦ 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