D2I_X509_CRL(3)
π D2I_X509_CRL β decode & encode X.509 CRLs (section 3 of the manual, bestie)
okay so this page lives in the Library Functions Manual, libcrypto girlie, and it's literally all about turning X.509 certificate revocation lists between DER bytes and structs. twelve functions, one page, we're doing this π«Ά
β¨ NAME β¨
d2i_X509_CRL, i2d_X509_CRL, d2i_X509_CRL_bio, d2i_X509_CRL_fp, i2d_X509_CRL_bio, i2d_X509_CRL_fp, d2i_X509_CRL_INFO, i2d_X509_CRL_INFO, d2i_X509_REVOKED, i2d_X509_REVOKED β decode and encode X.509 certificate revocation lists, no cap πΈ
π¦ SYNOPSIS π¦
library βlibcryptoβ #include <openssl/x509.h>
X509_CRL *
d2i_X509_CRL(X509_CRL **val_out, const unsigned char **der_in,
long length);
int
i2d_X509_CRL(X509_CRL *val_in, unsigned char **der_out);
X509_CRL *
d2i_X509_CRL_bio(BIO *in_bio, X509_CRL **val_out);
X509_CRL *
d2i_X509_CRL_fp(FILE *in_fp, X509_CRL **val_out);
int
i2d_X509_CRL_bio(BIO *out_bio, X509_CRL *val_in);
int
i2d_X509_CRL_fp(FILE *out_fp, X509_CRL *val_in);
X509_CRL_INFO *
d2i_X509_CRL_INFO(X509_CRL_INFO **val_out, const unsigned char **der_in,
long length);
int
i2d_X509_CRL_INFO(X509_CRL_INFO *val_in, unsigned char **der_out);
X509_REVOKED *
d2i_X509_REVOKED(X509_REVOKED **val_out, const unsigned char **der_in,
long length);
int
i2d_X509_REVOKED(X509_REVOKED *val_in, unsigned char **der_out);
π DESCRIPTION π
so these functions decode and encode X.509 certificate revocation lists. that's the vibe. π
heads up bestie: for the details on semantics, examples, caveats, and bugs, go read ASN1_item_d2i(3). like, actually go read it, i'm not joking π
d2i_X509_CRL()andi2d_X509_CRL()β decode and encode an ASN.1CertificateListstructure defined in RFC 5280 section 5.1. iconic behavior only πd2i_X509_CRL_bio(),d2i_X509_CRL_fp(),i2d_X509_CRL_bio(), andi2d_X509_CRL_fp()β same energy, except they decode or encode using aBIOorFILEpointer. convenient fr fr β¨d2i_X509_CRL_INFO()andi2d_X509_CRL_INFO()β decode and encode an ASN.1TBSCertListstructure defined in RFC 5280 section 5.1 π¦d2i_X509_REVOKED()andi2d_X509_REVOKED()β decode and encode an ASN.1 structure representing one element of therevokedCertificatesfield of the ASN.1TBSCertListstructure. just one little guy π₯
π SEE ALSO π
π STANDARDS π
RFC 5280: Internet X.509 Public Key Infrastructure Certificate and Certificate Revocation List (CRL) Profile, section 5: CRL and CRL Extensions Profile β
π§ HISTORY π§
a little lore for you bestie, because i KNOW you love a timeline:
d2i_X509_CRL(),i2d_X509_CRL(),d2i_X509_CRL_fp(),i2d_X509_CRL_fp(),d2i_X509_CRL_INFO(),i2d_X509_CRL_INFO(),d2i_X509_REVOKED(), andi2d_X509_REVOKED()first appeared in SSLeay 0.5.1 π±d2i_X509_CRL_bio()andi2d_X509_CRL_bio()first appeared in SSLeay 0.6.0 πΏ- these functions have been available since OpenBSD 2.4 π³
mwah π β this page is brought to you by the Debian build of the manual, dated June 8, 2025, and it's D2I_X509_CRL(3) out. go decode something, bestie πβ¨
π¦ where this page comes from
- alpine 3.24: libressl-doc 4.3.1-r0 Β· custom
- arch rolling: libressl 4.4.0-1 Β· ISC AND custom:OpenSSL
- Copyright (c) 2016, 2021 Ingo Schwarze <schwarze@openbsd.org>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms