OSSL_CRMF_MS...INFO_CERTREQ(3ossl)
π OSSL_CRMF_MSG_get0_regInfo_utf8Pairs, OSSL_CRMF_MSG_set1_regInfo_utf8Pairs, OSSL_CRMF_MSG_get0_regInfo_certReq, OSSL_CRMF_MSG_set1_regInfo_certReq β the CRMF Registration Info getters & setters π
okay so bestie, welcome to the 3ossl manual section πΈ this one is all about CRMF Registration Info β the little side-quest data you can bolt onto a certificate request message. it's giving "getting or setting CRMF Registration Info" and honestly? iconic. π
β¨ NAME β¨
OSSL_CRMF_MSG_get0_regInfo_utf8Pairs, OSSL_CRMF_MSG_set1_regInfo_utf8Pairs, OSSL_CRMF_MSG_get0_regInfo_certReq, OSSL_CRMF_MSG_set1_regInfo_certReq β functions getting or setting CRMF Registration Info π
π SYNOPSIS π
first things first, you gotta pull in the header, no cap:
#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 π¦
okay so, four functions, two flavors: getters and setters. the getters are the "gimme what's in there" girls, the setters are the "here, take a copy" girls. π«Ά
OSSL_CRMF_MSG_get0_regInfo_utf8Pairs()β returns the firstutf8PairsregInfo in the givenmsg, if present. if it's not there? you get nothing, bestie, and that's fine. πOSSL_CRMF_MSG_set1_regInfo_utf8Pairs()β adds a copy of the givenutf8pairsvalue asutf8PairsregInfo to the givenmsg. see RFC 4211 section 7.1 π (yes we cite our sources, we're not messy)OSSL_CRMF_MSG_get0_regInfo_certReq()β returns the firstcertReqregInfo in the givenmsg, if present. same energy as the first getter fr fr.OSSL_CRMF_MSG_set1_regInfo_certReq()β adds a copy of the givencrvalue ascertReqregInfo to the givenmsg. see RFC 4211 section 7.2 π
lowkey note: both setters copy the value in. you keep your original, they keep theirs. nobody's sharing pointers here, we're respectful. π
β RETURN VALUES β
- all the
get0_*()functions return the respective pointer value, andNULLif it's not present. simple as that. π - all the
set1_*()functions return1on success,0on error. slay or flop, binary, no in-between. π
π₯ NOTES π₯
okay this part is important so listen up bestie π
calling the set1_*() functions multiple times adds multiple instances of the respective control to the regInfo structure of the given msg. so you can stack 'em, technically.
BUT β and this is the plot twist π β while RFC 4211 expects multiple utf8Pairs in one regInfo structure, it does NOT allow multiple certReq. so like, multiple utf8Pairs? sure, go off. multiple certReq? absolutely not, that's not the vibe, RFC said no. π«
π SEE ALSO π
- RFC 4211 β the source material, the blueprint, the main character π
π§ HISTORY π§
the OpenSSL CRMF support was added in OpenSSL 3.0. so if you're on something older, sorry babe, it's not there. β¨
π COPYRIGHT π
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, you ate it, you understood it, periodt π and just so you have the receipts: this was OpenSSL 3.5.9, dated 2026-09-29 π bye bestie, go set some regInfo responsibly π¦πΈ
π¦ where this page comes from
- fedora 43: openssl-devel 1:3.5.9-1.fc43 Β· Apache-2.0
- fedora 43: openssl-devel 1:3.5.9-1.fc43 Β· Apache-2.0
- fedora 44: openssl-devel 1:3.5.9-1.fc44 Β· Apache-2.0
- fedora 44: openssl-devel 1:3.5.9-1.fc44 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms