asn1_number_of_elements(3)

πŸ“¦
version 4.21.0 Β· 5 versions
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, fedora 43, fedora 44, opensuse-leap 16.0, ubuntu resolute, ubuntu stonking

✨ NAME ✨

asn1_number_of_elements β€” bestie, it's an API function πŸ’– (from libtasn1, the ASN.1 girlies' fave)


🌸 SYNOPSIS 🌸

#include <libtasn1.h>

int asn1_number_of_elements(asn1_node_const element, const char * name,
                            int * num);

πŸŽ€ ARGUMENTS πŸŽ€

  • asn1_node_const element β€” okay so this is a pointer to the root of an ASN1 structure. like, the whole tree's main character πŸ‘‘
  • const char * name β€” the name of a sub-structure of ROOT. yes, the arg is called name and the docs keep yelling ROOT in caps, we love the drama 🫢
  • int * num β€” a pointer to an integer, and that's where the result gets stored. she's the delivery address for the answer πŸ“¬

πŸ’… DESCRIPTION πŸ’…

Not me counting things β€” but actually yes, that's literally the job πŸ’€

It counts the number of elements of a sub-structure called NAME, where the names are equal to "?1", "?2", ... etc. Lowkey iconic, highkey specific. Periodt. ✨


πŸ¦‹ RETURNS πŸ¦‹

  • ASN1_SUCCESS β€” slay, it worked, no notes 🌈
  • ASN1_ELEMENT_NOT_FOUND β€” if name is not known 😭 that sub-structure said "who are you" and left the chat
  • ASN1_GENERIC_ERROR β€” if the pointer num is NULL. like bestie you have to give her somewhere to put the answer πŸ™ˆ

Copyright Β© 2006-2025 Free Software Foundation, Inc..

Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved. (translation: go off, just keep the receipts πŸ’–)


🌟 SEE ALSO 🌟

The full documentation for libtasn1 is maintained as a Texinfo manual. If the info and libtasn1 programs are properly installed at your site, the command

info libtasn1

should give you access to the complete manual. As an alternative you may obtain the manual from:

https://www.gnu.org/software/libtasn1/manual/

and that's the whole vibe check bestie β€” this page is from libtasn1 version 4.21.0 (the asn1_number_of_elements(3) era, the date slot stayed empty so we're not gonna make one up, we are not that kind of girl πŸ’…βœ¨πŸŽ€)

πŸ“¦ where this page comes from