gnutls_cipher_encrypt(3)
π gnutls_cipher_encrypt β API function π
okay bestie, welcome to the gnutls manual, and specifically to gnutls_cipher_encrypt(3). this is the one that actually does the encrypting. the glow-up of your plaintext. the main character moment. let's go π«Ά
β¨ SYNOPSIS β¨
#include <gnutls/crypto.h>
int gnutls_cipher_encrypt(gnutls_cipher_hd_t handle, void * ptext,
size_t ptext_len);
like. look at it. three little params and it's out here changing lives π
π ARGUMENTS π
gnutls_cipher_hd_t handleβ bestie this is agnutls_cipher_hd_ttype. it's your cipher handle, your lil context baddie, and it's the one holding the algorithm tea.void * ptextβ the data to encrypt. yes, that's your plaintext, and yes, it's getting a whole new look β¨size_t ptext_lenβ the length of data to encrypt. gotta tell it how many bytes we're working with, no guessing games here π¦
πΈ DESCRIPTION πΈ
so what does this function actually do, you ask? it encrypts the given data using the algorithm specified by the context. that's it. that's the whole vibe. the context (aka your handle) already knows which algorithm it's on, so this function just takes your data and does the thing. no cap π₯
β RETURNS β
zero on success, or a negative error code on error. so if you get a negative number back, that's your signal that something went sideways β check it, don't ignore it, periodt π
π¦ SINCE π¦
2.10.0 β she's been iconic since 2.10.0, an absolute veteran π
π 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>
(not me giving you the exact email and URL, you're welcome π)
π 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. (yes bestie, it's free to share, 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 visit
<https://www.gnutls.org/manual/>
like, go read the whole thing, it's giving comprehensive π
and that's the page!! this was gnutls_cipher_encrypt(3) from gnutls version 3.8.13, brought to you with love. mwah. slay, stay encrypted, and drink water πβ¨π
π¦ 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