asn1_get_bit_der(3)
β¨ asn1_get_bit_der β¨
okay bestie, welcome to the libtasn1 corner of the man pages π
this one's asn1_get_bit_der(3), and she's literally an API function, no cap.
π NAME π
asn1_get_bit_der β it's an API function, that's the whole vibe π«Ά
π SYNOPSIS π
#include <libtasn1.h>
int asn1_get_bit_der(const unsigned char * der, int der_len, int *
ret_len, unsigned char * str, int str_size, int * bit_len);
like yes, that line break in the middle of int * and ret_len is just how the original wrapped it, we don't question the ancestors π
πΈ ARGUMENTS πΈ
const unsigned char * derβ the DER data to decode, and it's holding theBIT SEQUENCE. don't touch, it'sconstfor a reason π§int der_lenβ how long that DER data you're decoding is. length. that's it, that's the girl β¨int * ret_lenβ output variable, and she's carrying the length of the DER data. she gets written to, so she's a pointer, periodt.unsigned char * strβ a pre-allocated output buffer where the decodedBIT SEQUENCEgoes to live her best life. you allocate it, not the function, ok? πint str_sizeβ the length of that pre-allocated output buffer you so thoughtfully provided πint * bit_lenβ another output variable, this one holding the size of theBIT SEQUENCE. size queen behavior, honestly π
π DESCRIPTION π
Extract a BIT SEQUENCE from DER data.
that's it. that's the whole job. she extracts, she slays, she goes home π¦
β RETURNS β
ASN1_SUCCESS on success, or an error. like, on success you get ASN1_SUCCESS β which is the win β and if it's not that, it's an error. lowkey straightforward π₯
π COPYRIGHT π
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.
okay so real talk: that copyright line is the whole license situation, keep the notice and you're golden π
π 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 page bestie, go forth and decode π«Ά
libtasn1 β version 4.21.0 β asn1_get_bit_der(3) β¨ππ
π¦ where this page comes from
- alpine 3.22: libtasn1-doc 4.21.0-r0 Β· LGPL-2.1-or-later
- alpine 3.23: libtasn1-doc 4.21.0-r0 Β· LGPL-2.1-or-later
- alpine 3.24: libtasn1-doc 4.21.0-r0 Β· LGPL-2.1-or-later
- arch rolling: libtasn1 4.21.0-1 Β· GPL-3.0-or-later AND LGPL-2.1-or-later AND GFDL-1.3-or-later
- fedora 43: libtasn1-devel 4.21.0-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: libtasn1-devel 4.21.0-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: libtasn1-devel 4.21.0-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: libtasn1-devel 4.21.0-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: libtasn1-devel 4.21.0-160000.1.1 Β· GFDL-1.3-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: libtasn1-devel 4.21.0-160000.1.1 Β· GFDL-1.3-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: libtasn1-devel 4.21.0-160000.1.1 Β· GFDL-1.3-or-later AND LGPL-2.1-or-later
- opensuse-leap 16.0: libtasn1-devel 4.21.0-160000.1.1 Β· GFDL-1.3-or-later AND LGPL-2.1-or-later
- ubuntu resolute: libtasn1-6-dev 4.21.0-2
- ubuntu stonking: libtasn1-6-dev 4.21.0-2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms