gnutls_psk_set...known_dh_params(3)

πŸ’– gnutls_psk_set_server_known_dh_params πŸ’–

okay bestie, so this is a page from the gnutls manual β€” yeah, the big TLS library one β€” and we're about to get into some Diffie-Hellman-with-PSK lore that honestly ate. sit down, grab a boba, let's go πŸ§‹βœ¨


✨ NAME ✨

gnutls_psk_set_server_known_dh_params β€” literally just an API function, no cap


🌸 SYNOPSIS 🌸

#include <gnutls/gnutls.h>

int
gnutls_psk_set_server_known_dh_params(gnutls_psk_server_credentials_t
res, gnutls_sec_param_t sec_param);

like. that's the whole thing. short king fr πŸ’…


πŸŽ€ ARGUMENTS πŸŽ€

  • gnutls_psk_server_credentials_t res β€” this one is, shockingly, a gnutls_psk_server_credentials_t type. she is who she says she is πŸ‘‘
  • gnutls_sec_param_t sec_param β€” and this one is an option from the gnutls_sec_param_t enumeration. pick your vibe from the menu ✨

πŸ¦‹ DESCRIPTION πŸ¦‹

so this function sets the Diffie-Hellman parameters that a PSK server is gonna use. obsessed.

those parameters get used in Ephemeral Diffie-Hellman cipher suites, and they're selected from the FFDHE set of RFC7919 β€” according to whatever security level you handed over in sec_param. so like, you say how much security you want, and it picks the matching FFDHE crew. no cap, that's it 🫢


πŸ’€ DEPRECATED πŸ’€

girl. listen to me. this function is unnecessary and discouraged on GnuTLS 3.6.0 or later. since 3.6.0, DH parameters are negotiated following RFC7919 all on their own, like the main character it is. so if you're on 3.6.0+, you do not need this. periodt. 😭

⭐ RETURNS ⭐

on success you get GNUTLS_E_SUCCESS (which is 0, iconic), otherwise you get a negative error value. so if it's negative… yeah. something's up πŸ™ˆ


🌈 SINCE 🌈

3.5.6 β€” a true 2015-era baddie πŸ’œ


πŸ“ REPORTING BUGS πŸ“

found a bug? spill the tea to <bugs@gnutls.org>.

home page: https://www.gnutls.org


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. (fr fr, just keep the notice 🫢)


πŸ”₯ 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, go visit:

https://www.gnutls.org/manual/

and that's the whole page, bestie!! mwah πŸ’–

this was gnutls 3.8.13 telling you everything you need to know, and no date because the manpage said so, iykyk βœ¨πŸŽ€πŸ¦‹πŸ’…

πŸ“¦ where this page comes from