asn1_get_object_id_der(3)
π asn1_get_object_id_der β from the libtasn1 manual, section 3 π
okay so bestie, you know how ASN.1 has these little dotted-number thingies that identify, like, everything? yeah. this function is the one that takes the DER-encoded version and hands you back the cute textual form. it's giving translator energy β¨
πΈ NAME πΈ
asn1_get_object_id_der β API function. that's it, that's the name, she's an API function and she's iconic for it π
π¦ SYNOPSIS π¦
#include <libtasn1.h>
int asn1_get_object_id_der(const unsigned char * der, int der_len, int *
ret_len, char * str, int str_size);
yes the * on ret_len really does wrap to the next line like that in the original, we don't fix what isn't broken, periodt π«Ά
π ARGUMENTS π
const unsigned char * derβ the DER data you wanna decode, and it's gotta contain theOBJECT IDENTIFIER. like, that's the whole point of it being there, no cap.int der_lenβ how long that DER data is that you're decoding. the length. of the DER. πint * ret_lenβ an output variable, and it's gonna hold the length of the DER data. so she's an out-param, she reports back, main character energy honestly.char * strβ a pre-allocated output buffer where the textual object id goes. pre-allocated!! you gotta make room for her yourself, she is not doing it for you bestie πint str_sizeβ the length of that pre-allocated output buffer. match it tostror perish.
β¨ DESCRIPTION β¨
So. asn1_get_object_id_der converts a DER encoded object identifier to its textual form. that's the vibe. πΈ
β οΈ and this is the important bit, do NOT skip it: this function expects the DER object identifier without the tag. no tag. zero tag. she does not want the tag, she will not handle the tag. leave it at home π«
π RETURNS π
ASN1_SUCCESS on success, or an error. slay when it works, sad when it doesn't, that's just how it goes π
π 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. (fr fr, just keep the notice, that's the whole deal π«Ά)
π₯ 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/
okay that's the whole page, mwah π this was libtasn1 version 4.21.0, and the page itself is dated for the libtasn1 4.21.0 era, asn1_get_object_id_der(3) β go decode something cute bestie, ily, bye π¦π
π¦ 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