CMS_ENCRYPTEDDATA_SET1_KEY(3SSL)
π NAME π
CMS_EncryptedData_set1_key β bestie, this is the one that sets the cipher and the key for a CMS EncryptedData π
β¨ SYNOPSIS β¨
#include <openssl/cms.h>
int CMS_EncryptedData_set1_key(CMS_ContentInfo *cms, const EVP_CIPHER *ciph,
const unsigned char *key, size_t keylen);
π¦ DESCRIPTION π¦
okay so CMS_EncryptedData_set1_key()</p> rolls up to a cms EncryptedData object and sets the appropriate attributes over to ciph β like, it literally hands the whole vibe over to that cipher. and then π
it makes a copy of the symmetric key of size keylen, so your key is safe, she's got her own little duplicate, no sharing, no cap.
π¨ IMPORTANT GIRLIE WARNING π¨ β AEAD cipher algorithms are not supported. like, at all. do not come for her with an AEAD, she will not answer the phone. π
πΈ RETURN VALUES πΈ
0β something went wrong, an error occurred, we're crying π1β slay!! everything worked, no error, we ate π
so basically it returns 0 if an error occurred, otherwise it returns 1. that's the whole thing. periodt. β¨
π«Ά SEE ALSO π«Ά
go read those next bestie, they're the whole friend group π
π COPYRIGHT π
Copyright 2025 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>.
k that's the whole page, you understood all of it, iconic behavior fr fr π§π
this was CMS_ENCRYPTEDDATA_SET1_KEY(3SSL) from the OpenSSL manual, version 4.0.3, dated 2026-09-29 β mwah, catch you on the next one bestie πβ¨
π¦ 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