OSSL_CMP_STATUSINFO_NEW(3ossl)

πŸ“¦ version 3.5.0, in opensuse-leap 16.0

πŸ’… OSSL_CMP_STATUSINFO_NEW β€” the tea on 3ossl

ok so bestie, welcome to the CMP PKIStatus page πŸ’– this one lives in section 3ossl of the OpenSSL manual, and it's literally all about creating and pretty-printing the CMP PKIStatus. let's get into it πŸŽ€

✨ SYNOPSIS ✨

#include <openssl/cmp.h>

OSSL_CMP_PKISI *OSSL_CMP_STATUSINFO_new(int status, int fail_info,
                                        const char *text);
char *OSSL_CMP_snprint_PKIStatusInfo(const OSSL_CMP_PKISI *statusInfo,
                                     char *buf, size_t bufsize);
char *OSSL_CMP_CTX_snprint_PKIStatus(const OSSL_CMP_CTX *ctx, char *buf,
                                     size_t bufsize);

like, that's the whole cast of characters right there πŸ‘‘ three functions, one header, no cap.


🌸 DESCRIPTION 🌸

so this is the PKIStatus API for using CMP (Certificate Management Protocol) with OpenSSL. yes queen, CMP in OpenSSL, we love to see it πŸ¦‹

Here's what each function is giving:

  • OSSL_CMP_STATUSINFO_new() β€” creates a brand new PKIStatusInfo structure and fills in the given values. It sets the status field to status, copies text (unless it is NULL) to statusString, and interprets fail_info as a bit pattern for the failInfo field. like it's doing the absolute most and we stan 🫢
  • OSSL_CMP_snprint_PKIStatusInfo() β€” places a human-readable string representing the given statusInfo in the given buffer, with the given maximal length. it's giving "make it readable for the girlies" energy ✨
  • OSSL_CMP_CTX_snprint_PKIStatus() β€” places a human-readable string representing the PKIStatusInfo components of the CMP context ctx in the given buffer, with the given maximal length. same vibe, but pulling from the whole context instead of just one struct πŸ’…

⭐ NOTES ⭐

CMP is defined in RFC 4210 (and CRMF in RFC 4211). iykyk πŸ“š


πŸ”₯ RETURN VALUES πŸ”₯

  • OSSL_CMP_STATUSINFO_new() returns a pointer to the structure on success, or NULL on error. so like, if you get NULL bestie, something went wrong 😭
  • OSSL_CMP_snprint_PKIStatusInfo() and OSSL_CMP_CTX_snprint_PKIStatus() return a copy of the buffer pointer containing the string or NULL on error. same deal β€” NULL means error, don't ignore it πŸ™ˆ

πŸ•°οΈ HISTORY πŸ•°οΈ

The OpenSSL CMP support was added in OpenSSL 3.0. so it's a 3.0 baby, born iconic πŸ‘‘


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>.

fr fr read the license before you do anything spicy with this, bestie β€” "not in compliance with the License" is not the vibe we're going for πŸ’€

ok that's the whole page πŸŽ€ mwah, go forth and print your PKIStatuses pretty ✨

sign-off szn: this tea was served up from the OpenSSL manual, version 3.5.0, dated 2026-09-25, and the page itself goes by OSSL_CMP_STATUSINFO_NEW(3ossl) β€” catch you on the next one, bestie πŸ’–πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from