I2D_CMS_BIO_STREAM(3ossl)
β¨ i2d_CMS_bio_stream π
okay bestie, welcome to the 3ossl girlies' corner of the manual galaxy π this one's a little function with a big job and honestly a slightly misleading name, but we'll get there. sit down, hydrate, let's go π«Ά
πΈ NAME πΈ
i2d_CMS_bio_stream β writes out a CMS_ContentInfo structure in BER format, straight into a BIO. that's the whole vibe π
β SYNOPSIS β
#include <openssl/cms.h>
int i2d_CMS_bio_stream(BIO *out, CMS_ContentInfo *cms, BIO *data, int flags);
like, that's it. that's the signature. iconic, no notes π
π¦ DESCRIPTION π¦
okay so i2d_CMS_bio_stream() takes a CMS_ContentInfo structure and outputs it in BER format. periodt.
and here's the tea: it's otherwise identical to the function SMIME_write_CMS(). like, literally the same energy, same behaviour, no cap π§
π₯ NOTES π₯
this function is effectively a version of i2d_CMS_bio() that supports streaming. so like, same friend group, different main character energy β¨
π BUGS π
ngl, the i2d prefix is arguably wrong here, because the function outputs BER format. like bestie, the name is giving false advertising π we said what we said.
π RETURN VALUES π
i2d_CMS_bio_stream() returns 1 for success or 0 for failure. that's it. simple king behaviour π
π SEE ALSO π
ERR_get_error(3)CMS_sign(3)CMS_verify(3)CMS_encrypt(3)CMS_decrypt(3)SMIME_write_CMS(3)PEM_write_bio_CMS_stream(3)
go read those too, they're all in the same cinematic universe π¬
π HISTORY π
the i2d_CMS_bio_stream() function was added in OpenSSL 1.0.0. a legend from the start π
π COPYRIGHT π
Copyright 2008-2016 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>.
and that's a wrap, bestie π«Ά this page is from OpenSSL 3.5.6, dated 2026-04-07, and you found it under the manual name I2D_CMS_BIO_STREAM(3ossl). go stream those BER outputs, you absolute icon ππ
π¦ where this page comes from
- freebsd 15.1: base 15.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms