ASN1_ITEM_NEW(3ossl)

πŸ“¦ version 3.5.0, in opensuse-leap 16.0

okay bestie, welcome to ASN1_ITEM_NEW(3ossl) β€” the OpenSSL manual page for making new ASN.1 values. we’re gonna keep it cute and keep every detail, mkay? πŸ’–

🌸 NAME 🌸

ASN1_item_new_ex, ASN1_item_new β€” create new ASN.1 values ✨

✨ SYNOPSIS ✨

#include <openssl/asn1.h>

ASN1_VALUE *ASN1_item_new_ex(const ASN1_ITEM *it, OSSL_LIB_CTX *libctx,
                             const char *propq);
ASN1_VALUE *ASN1_item_new(const ASN1_ITEM *it);

πŸ’… DESCRIPTION πŸ’…

okay so ASN1_item_new_ex() creates a brand-new ASN1_VALUE structure based on the ASN1_ITEM template you pass in through the it parameter. If any algorithm fetches are required during the process, they’re gonna use the OSSL_LIB_CTX provided in the libctx parameter and the property query string in propq. for the full tea on algorithm fetching, see "ALGORITHM FETCHING" in crypto(7) β€” yep, that’s the section to check, iykyk 🫢

ASN1_item_new() is literally the same as ASN1_item_new_ex() except that the default OSSL_LIB_CTX is used (i.e. NULL) and with a NULL property query string. periodt πŸ’…

🌈 RETURN VALUES 🌈

ASN1_item_new_ex() and ASN1_item_new() return a pointer to the newly created ASN1_VALUE, or NULL on error. that’s it, no cap ✨

πŸ¦‹ HISTORY πŸ¦‹

The function ASN1_item_new_ex() was added in OpenSSL 3.0. iconic behavior, honestly πŸ‘‘

Copyright 2021 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>. 🫢

okay bye bestie β€” this page is from source/version 3.5.0 and dated 2026-09-25. mwah πŸ’‹βœ¨

πŸ“¦ where this page comes from