GNUTLS_X509_CRT_SET_ISSUER_DN_BY_OID(3)
π gnutls_x509_crt_set_issuer_dn_by_oid β the manual page bestie π
okay so this is a page from the gnutls manual (section 3, the library functions girlies), and it's all about one very specific lil API function. buckle up π
β¨ NAME β¨
gnutls_x509_crt_set_issuer_dn_by_oid β literally an API function, that's the whole name, no notes π
πΈ SYNOPSIS πΈ
#include <gnutls/x509.h>
int gnutls_x509_crt_set_issuer_dn_by_oid(gnutls_x509_crt_t crt, const
char * oid, unsigned int raw_flag, const void * name, unsigned int
sizeof_name);
bestie look at that signature, she's serving parameters π«Ά
π¦ ARGUMENTS π¦
gnutls_x509_crt_t crtβ a certificate of typegnutls_x509_crt_t. the main character we're editing, periodt.const char * oidβ holds an Object Identifier in a null terminated string. yes it's a whole string, yes it's null terminated, we love that for it β¨unsigned int raw_flagβ must be0, or1if the data are DER encoded. no other values, don't try it πconst void * nameβ a pointer to the name. just a pointer. pointing at the name. iconic.unsigned int sizeof_nameβ holds the size of name. she's the measuring tape of the group π
π DESCRIPTION π
so what does this function actually DO. okay so it sets the part of the name of the Certificate issuer, specified by the given OID. that's the vibe. the input string should be ASCII or UTF-8 encoded β keep it cute, keep it standard.
some helper macros with popular OIDs can be found in gnutls/x509.h, so go look there if you want the pre-approved list π
β οΈ with this function you can only set the known OIDs. that's the rule, no cap.
you can test for known OIDs using gnutls_x509_dn_oid_known(). for OIDs that are not known (by gnutls) you should properly DER encode your data, and call this function with raw_flag set. like, do the homework first, then come back π
and honestly? normally you do not need to call this function, since the signing operation will copy the signer's name as the issuer of the certificate. so likeβ¦ she's here if you need her, but the algorithm kinda handles it for you. lowkey convenient π₯
β RETURNS β
on success, GNUTLS_E_SUCCESS (0) is returned. otherwise you get a negative error value, which is giving "we need to talk" energy π
π REPORTING BUGS π
found a bug? don't be shy, report it, the maintainers want to know fr fr:
- Report bugs to
<bugs@gnutls.org>. - Home page: https://www.gnutls.org
π COPYRIGHT π
Copyright Β© 2001-2023 Free Software Foundation, Inc., and others.
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. slay, that's genuinely generous of them π
π SEE ALSO π
the full documentation for gnutls is maintained as a Texinfo manual. if the /usr/share/doc/gnutls/ directory does not contain the HTML form, visit:
https://www.gnutls.org/manual/
that's the plug, that's where the lore lives π
π« and that's the whole page bestie, you understood it, i'm so proud of you, main character energy all the way through π«Ά
gnutls version 3.8.13, copyright 2001-2023 β mwah, go set some issuer DNs, love u bye π
β¨π¦
π¦ where this page comes from
- alpine 3.22: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- alpine 3.23: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- alpine 3.24: gnutls-doc 3.8.13-r0 Β· LGPL-2.1-or-later
- arch rolling: gnutls 3.8.13-3 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: gnutls-devel 3.8.13-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 43: gnutls-devel 3.8.13-1.fc43 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: gnutls-devel 3.8.13-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- fedora 44: gnutls-devel 3.8.13-1.fc44 Β· GPL-3.0-or-later AND LGPL-2.1-or-later
- ubuntu stonking: gnutls-doc 3.8.13-1ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms