OSSL_CRMF_MSG...GINFO_CERTREQ(3SSL)

πŸ’– OSSL_CRMF_MSG_get0_regInfo_utf8Pairs, OSSL_CRMF_MSG_set1_regInfo_utf8Pairs, OSSL_CRMF_MSG_get0_regInfo_certReq, OSSL_CRMF_MSG_set1_regInfo_certReq β€” NAME ✨

okay bestie so this is the OSSL_CRMF_MSG...GINFO_CERTREQ page from the OpenSSL manual (section 3SSL, we love a library page 🌸), and it's literally all about the functions that get or set the CRMF Registration Info. yes we're doing certificate request message format today, get into it πŸ’…


🌈 SYNOPSIS 🌈

#include <openssl/crmf.h>

ASN1_UTF8STRING
    *OSSL_CRMF_MSG_get0_regInfo_utf8Pairs(const OSSL_CRMF_MSG *msg);
int OSSL_CRMF_MSG_set1_regInfo_utf8Pairs(OSSL_CRMF_MSG *msg,
                                         const ASN1_UTF8STRING *utf8pairs);
OSSL_CRMF_CERTREQUEST
    *OSSL_CRMF_MSG_get0_regInfo_certReq(const OSSL_CRMF_MSG *msg);
int OSSL_CRMF_MSG_set1_regInfo_certReq(OSSL_CRMF_MSG *msg,
                                       const OSSL_CRMF_CERTREQUEST *cr);

πŸ¦‹ DESCRIPTION πŸ¦‹

so there's four functions and they're basically two little duos, and they GO together like this:

  • OSSL_CRMF_MSG_get0_regInfo_utf8Pairs() β€” hands you back the first utf8Pairs regInfo chillin' inside the given msg, if it's even there πŸ‘€
  • OSSL_CRMF_MSG_set1_regInfo_utf8Pairs() β€” drops a copy of the utf8pairs value you gave it into the given msg as a utf8Pairs regInfo. and like, go read RFC 4211 section 7.1 for the lore, iykyk πŸ“–
  • OSSL_CRMF_MSG_get0_regInfo_certReq() β€” same energy, different field: gives you the first certReq regInfo in the given msg, if present πŸ’«
  • OSSL_CRMF_MSG_set1_regInfo_certReq() β€” sticks a copy of your cr value in as a certReq regInfo on the given msg. RFC 4211 section 7.2 is where the deets live, periodt ✨

πŸŽ€ RETURN VALUES πŸŽ€

  • All the get0_*() functions return the respective pointer value, and NULL if it's not present. no notes, that's the whole vibe 🫢
  • All the set1_*() functions return 1 on success, 0 on error. classic. iconic. we respect it πŸ’…

πŸ”₯ NOTES πŸ”₯

okay this is the part where you listen, bestie:

If you call the set1_*() functions multiple times, you get multiple instances of the respective control added into the regInfo structure of the given msg. so it just keeps stacking, like my unread notifications 😭

and the plot twist: RFC 4211 actually expects multiple utf8Pairs inside one regInfo structure, which is fine and cute and encouraged. BUT it does **not allow multiple certReq. so like, don't do that one. fr fr. that's the rule πŸ”₯


🌟 SEE ALSO 🌟


πŸ‘‘ HISTORY πŸ‘‘

The whole OpenSSL CRMF support situation walked in the door in OpenSSL 3.0. a glow-up era truly πŸ’–


Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.

Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.


okay that's the whole page bestie, no cap πŸ§šπŸ’œ this was OpenSSL 4.0.3, dated 2026-09-2, and honestly? she ate. go forth and manage your regInfo responsibly πŸ‘‘πŸŒΈ

πŸ“¦ where this page comes from