SCT_PRINT(3ossl)

✨ SCT_print, SCT_LIST_print, SCT_validation_status_string πŸ’–

okay bestie so this is the SCT_PRINT(3ossl) page from the OpenSSL manual, and we're about to make Signed Certificate Timestamps look cute and readable, no cap πŸŽ€


🌸 NAME 🌸

SCT_print, SCT_LIST_print, SCT_validation_status_string β€” these three girlies print Signed Certificate Timestamps in a human-readable way πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <openssl/ct.h>

void SCT_print(const SCT *sct, BIO *out, int indent, const CTLOG_STORE *logs);
void SCT_LIST_print(const STACK_OF(SCT) *sct_list, BIO *out, int indent,
                    const char *separator, const CTLOG_STORE *logs);
const char *SCT_validation_status_string(const SCT *sct);

πŸ’œ DESCRIPTION πŸ’œ

So SCT_print() prints a single Signed Certificate Timestamp β€” an SCT, iykyk β€” to a BIO, in a human-readable format. Because raw bytes are giving unreadable 😭

SCT_LIST_print() does basically the same thing but for an entire list of SCTs. And because a list needs boundaries, you can specify a separator to delimit each SCT in the output ✨

The output can also be indented by a specified number of spaces. Cute, right? πŸŽ€

If you pass in a CTLOG_STORE, it gets used to print the description of the CT log that issued each SCT β€” but only if that log is actually in the CTLOG_STORE. And if you don't want that feature at all? Just pass NULL as the CTLOG_STORE parameter to disable it. Simple as that, periodt 🫢

SCT_validation_status_string() returns the validation status of an SCT as a human-readable string. But β€” and this is the important part, bestie β€” you have to call SCT_validate() or SCT_LIST_validate() beforehand in order to set the validation status of an SCT first. No validation, no status, no string. Do it in the right order πŸ”₯


πŸ‘‘ RETURN VALUES πŸ‘‘

SCT_validation_status_string() returns a NUL-terminated string representing the validation status of an SCT object. That's it, that's the return value 🌈


πŸ’€ SEE ALSO πŸ’€


πŸ“œ HISTORY πŸ“œ

These functions were added in OpenSSL 1.1.0. Old but iconic ⭐


Copyright 2016-2018 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 up fr fr πŸ’– this was OpenSSL 3.5.9, dated 2026-09-29, and it lives in the SCT_PRINT(3ossl) manual. go forth and print those timestamps, main character 🧚✨

πŸ“¦ where this page comes from