gnutls_priority_set_direct(3)
π gnutls_priority_set_direct β the glow-up your TLS session's priorities deserve π
okay bestie, so this is a page from the gnutls manual, and today's main character is gnutls_priority_set_direct(3). yes it's an "API function," no it's not boring, come with me π¦
β¨ SYNOPSIS β¨
#include <gnutls/gnutls.h>
int gnutls_priority_set_direct(gnutls_session_t session, const char *
priorities, const char ** err_pos);
π ARGUMENTS π
gnutls_session_t sessionβ it's agnutls_session_ttype, periodt. that's the whole vibe.const char * prioritiesβ a string that describes your priorities. like, the string is the priorities. iykyk.const char ** err_posβ if something goes wrong, this bad boy gets pointed at the exact position in the string where the error happened. super helpful, ngl π«Ά
πΈ DESCRIPTION πΈ
so what it does: it sets the priorities to use on the ciphers, key exchange methods, and macs. iconic behavior honestly.
this function avoids keeping a priority cache, and instead it's used to directly set string priorities to a TLS session. it's giving lowkey efficient, highkey specific π
for documentation on all this, go check gnutls_priority_init() β that's where the lore lives π
and bestie, listen: to use a reasonable default, consider usinggnutls_set_default_priority(), orgnutls_set_default_priority_append()instead of this function. fr fr, don't make your life harder than it needs to be π
β RETURNS β
- on a syntax error, you get
GNUTLS_E_INVALID_REQUESTπ - on success, you get
GNUTLS_E_SUCCESSβ¨ - or, you know, just an error code. as a treat. π
π REPORTING BUGS π
found a bug? don't be shy, tell the girlies:
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.
(that's the legal tea, and we're respecting it fully π)
π§ 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's from gnutls 3.8.13, and if you were wondering about the date, it's just gnutls_priority_set_direct(3) doing its thing at the bottom of the page like a little signature. go set those priorities and slay π
β¨π¦
π¦ 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