gnutls_session_set_data(3)
β¨ gnutls_session_set_data β¨
okay bestie, welcome to the gnutls manual π this lil page is gnutls_session_set_data(3) and it's lowkey one of the most useful glow-ups in the whole session-resumption saga. sit down, grab a strawberry π, we're doing this.
πΈ SYNOPSIS πΈ
#include <gnutls/gnutls.h>
int gnutls_session_set_data(gnutls_session_t session, const void *
session_data, size_t session_data_size);
π ARGUMENTS π
gnutls_session_t sessionβ bestie this is literally just agnutls_session_ttype. that's it. that's the vibe.const void * session_dataβ a pointer to the space that's gonna hold the session π«Άsize_t session_data_sizeβ the size of that session, no cap
π DESCRIPTION π
so the way this works: it sets all the session parameters, so you can resume a session you already established earlier. iconic behaviour, truly main character energy β¨
the session data you hand over must be the exact stuff that came back from gnutls_session_get_data(). don't be out here freelancing with random bytes π
and like, call this function before gnutls_handshake(). before. periodt. π
okay important heads-up bestie: session resuming is advisory. the server is fully allowed to look at your cute little resume request and go "nah". if that happens, a full handshake gets performed instead. not me being ignored by the server π it's giving unread message.
π RETURNS π
if it slays: GNUTLS_E_SUCCESS (that's 0) comes back to you π₯³
if it doesn't: you get an error code instead. vibe check failed, but at least you know.
π REPORTING BUGS π
found a bug? don't suffer in silence, 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. (so like, go off, just keep the receipts π§Ύβ¨)
π₯ 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, you ate it π this was gnutls_session_set_data(3) from the gnutls manual, version 3.8.13 β thanks for reading, mwah, go resume some sessions responsibly π¦ππ
π¦ 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