EVP_CIPHER_CTX_GET_APP_DATA(3SSL)
π EVP_CIPHER_CTX_GET_APP_DATA(3SSL) π
okay bestie, welcome to the OpenSSL section 3SSL glow-up β¨ this one's short and sweet and honestly? it's giving "attach your own little backpack to the cipher context" energy π
β¨ NAME β¨
EVP_CIPHER_CTX_get_app_data, EVP_CIPHER_CTX_set_app_data β the little routines that let you peek at and poke at the application data hanging off an EVP_CIPHER_CTX π«Ά
πΈ SYNOPSIS πΈ
like, here's the whole vibe, no cap:
#include <openssl/evp.h>
void *EVP_CIPHER_CTX_get_app_data(const EVP_CIPHER_CTX *ctx);
void EVP_CIPHER_CTX_set_app_data(EVP_CIPHER_CTX *ctx, void *data);
π¦ DESCRIPTION π¦
so EVP_CIPHER_CTX_set_app_data() and EVP_CIPHER_CTX_get_app_data() are the duo that lets you associate an opaque, application-defined pointer with an EVP_CIPHER_CTX object. that's it. that's the whole job π
and the tea is: this pointer is not interpreted by the library. it is reserved entirely for use by the application π meaning the library will literally never look inside it, judge it, or touch it. it's yours. it's your main character pointer.
what's it for? literally whatever you want, bestie β it may be used to store arbitrary context or state that needs to be accessible wherever the corresponding EVP_CIPHER_CTX is available. so if you've got some state that needs to ride along with the cipher context and be reachable from anywhere that context shows up? this is the hook for that π
β RETURN VALUES β
the EVP_CIPHER_CTX_get_app_data() function returns a opaque pointer to the current application data for the EVP_CIPHER_CTX. yes, the original said "a opaque" and we are respectfully preserving that π«‘ (also lowkey, EVP_CIPHER_CTX_set_app_data() doesn't get a return value called out here β it's the setter, it just sets β¨)
π COPYRIGHT π
Copyright 2026 The OpenSSL Project Authors. All Rights Reserved. π
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.
fr fr, read the license before you ship it, bestie π
okay that's the whole page, and periodt π this was OpenSSL version 4.0.3, dated 2026-09-29, manual page EVP_CIPHER_CTX_GET_APP_DATA(3SSL) β slay, go forth and store your little pointer πΈπ¦β¨
π¦ where this page comes from
- ubuntu stonking: libssl-doc 4.0.3-1ubuntu1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms