EVP_PKEY_CTX_GET_ALGOR(3SSL)
π EVP_PKEY_CTX_GET_ALGOR π
okay bestie, welcome to EVP_PKEY_CTX_GET_ALGOR(3SSL) β this is the girlies' guide to handing AlgorithmIdentifiers back and forth with algorithm implementations π¦β¨
β¨ NAME β¨
EVP_CIPHER_CTX_get_algor</p>, EVP_CIPHER_CTX_get_algor_params</p>, EVP_CIPHER_CTX_set_algor_params</p>, EVP_PKEY_CTX_get_algor</p>, EVP_PKEY_CTX_get_algor_params</p>, EVP_PKEY_CTX_set_algor_params</p> β passing an AlgorithmIdentifier and its params to and from algorithm implementations, no cap π
β¨ SYNOPSIS β¨
int EVP_TYPE_CTX_get_algor(EVP_TYPE_CTX *ctx, X509_ALGOR **alg);
int EVP_TYPE_CTX_get_algor_params(EVP_TYPE_CTX *ctx, X509_ALGOR *alg);
int EVP_TYPE_CTX_set_algor_params(EVP_TYPE_CTX *ctx, const X509_ALGOR *alg);
β¨ DESCRIPTION β¨
so like, in this whole description and in the SYNOPSIS up there β¬οΈ, TYPE is serving as a lil placeholder for, literally, any EVP operation type. it's giving "insert your fave here" π
πΈ EVP_TYPE_CTX_get_algor()
she attempts to retrieve a whole entire AlgorithmIdentifier from the EVP_TYPE implementation, and populates *alg with it. π«
if alg is NULL, calling her is lowkey just a vibe check β it tells you whether calling this function is even supported at all by the EVP_TYPE implementation. π
and if *alg is NULL, space gets allocated automatically and assigned to *alg. iconic, she does it herself. β¨
π EVP_TYPE_CTX_get_algor_params()
she attempts to retrieve the parameters part of an AlgorithmIdentifier from the EVP_TYPE implementation and populates alg-parameters> with it. same energy as above: if alg is NULL, calling her is just the support-check vibe check for the EVP_TYPE implementation. π«Ά
if alg->parameters is NULL, space will be allocated automatically and assigned to alg->parameters. π
if alg->parameters is not NULL... girl. π its previous contents will be overwritten with the retrieved AlgorithmIdentifier parameters. Beware! π
π¦ EVP_TYPE_CTX_set_algor_params()
she attempts to pass alg->parameters to the EVP_TYPE implementation. and yep, you already know β if alg is NULL, calling her serves to see if calling her is supported at all by the EVP_TYPE implementation. main character check-in behavior fr fr π
β¨ RETURN VALUES β¨
all of these functions return 1 for success π and 0 or a negative number if an error occurs π.
in particular, -2 is returned when the function isn't supported by the EVP_TYPE implementation. not supported = not invited, periodt. π
β¨ HISTORY β¨
these functions were added in OpenSSL 3.4. new girls on the block, we love to see it πΈβ¨
β¨ COPYRIGHT β¨
Copyright 2024 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>. π
mwah π that's the whole page bestie β go forth and pass those AlgorithmIdentifiers around responsibly.
version 4.0.3 Β· dated 2026-09-29 Β· signing off, xoxo π«Άπ
π¦ 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