gnutls_pkcs12_get_bag(3)

πŸ’– gnutls_pkcs12_get_bag(3) β€” the gnutls manual, bestie edition πŸ’–

okay so. this is a page from the gnutls manual, and today's main character is gnutls_pkcs12_get_bag. it's an API function, it lives in the gnutls library, and honestly? it's giving "grab one bag out of the whole PKCS12 pile" energy. πŸŽ€


✨ NAME ✨

gnutls_pkcs12_get_bag β€” API function 🫢


🌸 SYNOPSIS 🌸

#include <gnutls/pkcs12.h>

int gnutls_pkcs12_get_bag(gnutls_pkcs12_t pkcs12, int indx,
gnutls_pkcs12_bag_t bag);

πŸ¦‹ ARGUMENTS πŸ¦‹

  • gnutls_pkcs12_t pkcs12 β€” a pkcs12 type. yes bestie, that's the whole description, we love a low-effort icon. πŸ’…
  • int indx β€” holds the index of the bag you wanna extract. it's your little number, your pick-a-bag ticket. πŸ”’
  • gnutls_pkcs12_bag_t bag β€” an initialized bag, and this is where the contents of the bag get copied into. so you're not making a bag, you're bringing an empty one and letting it get filled. πŸ‘œβœ¨

πŸ’œ DESCRIPTION πŸ’œ

so this function will return a Bag from the PKCS12 structure. that's it. that's the vibe. it reaches into your pkcs12 and pulls out a bag. 🧚

and listen β€” after the last Bag has been read, GNUTLS_E_REQUESTED_DATA_NOT_AVAILABLE gets returned. so when you hit that, it's not a glitch, it's the end. no more bags, the party's over, go home. 😭

⭐ RETURNS ⭐

on success, GNUTLS_E_SUCCESS (0) is returned. slay. otherwise you get a negative error value, which is the universe telling you something went sideways. πŸ’€


🌈 REPORTING BUGS 🌈

found a bug? don't be shy, tell the girlies:


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. iconic, fr fr. πŸ’–


πŸ“ 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/


and that's the whole page, bestie, no cap. this was gnutls version 3.8.13, and we ate. πŸŽ€βœ¨πŸ’…

πŸ“¦ where this page comes from