From: Dr. David von Oheimb Date: Thu, 17 Feb 2022 18:43:55 +0000 (+0100) Subject: X509V3_get_d2i.pod: Fix glitch on X509V3_get{,_ext}_d2i and align order X-Git-Tag: openssl-3.2.0-alpha1~2921 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2455a21f4ef9826b465ba68fd96f26ea25b80b10;p=thirdparty%2Fopenssl.git X509V3_get_d2i.pod: Fix glitch on X509V3_get{,_ext}_d2i and align order Reviewed-by: Tomas Mraz Reviewed-by: Matt Caswell (Merged from https://github.com/openssl/openssl/pull/17724) --- diff --git a/doc/man3/X509V3_get_d2i.pod b/doc/man3/X509V3_get_d2i.pod index 981eab14b87..4098f9aa6f3 100644 --- a/doc/man3/X509V3_get_d2i.pod +++ b/doc/man3/X509V3_get_d2i.pod @@ -2,11 +2,12 @@ =head1 NAME -X509_get0_extensions, X509_CRL_get0_extensions, X509_REVOKED_get0_extensions, X509V3_get_d2i, X509V3_add1_i2d, X509V3_EXT_d2i, X509V3_EXT_i2d, -X509_get_ext_d2i, X509_add1_ext_i2d, X509_CRL_get_ext_d2i, -X509_CRL_add1_ext_i2d, X509_REVOKED_get_ext_d2i, -X509_REVOKED_add1_ext_i2d - X509 extension decode and encode functions +X509_get_ext_d2i, X509_add1_ext_i2d, +X509_CRL_get_ext_d2i, X509_CRL_add1_ext_i2d, +X509_REVOKED_get_ext_d2i, X509_REVOKED_add1_ext_i2d, +X509_get0_extensions, X509_CRL_get0_extensions, +X509_REVOKED_get0_extensions - X509 extension decode and encode functions =head1 SYNOPSIS @@ -38,7 +39,7 @@ X509_REVOKED_add1_ext_i2d - X509 extension decode and encode functions =head1 DESCRIPTION -X509V3_get_ext_d2i() looks for an extension with OID B in the extensions +X509V3_get_d2i() looks for an extension with OID B in the extensions B and, if found, decodes it. If B is B then only one occurrence of an extension is permissible otherwise the first extension after index B<*idx> is returned and B<*idx> updated to the location of the extension. @@ -104,7 +105,8 @@ B extension B is deleted: no new extension is added. If B is ored with B: any error returned will not be added to the error queue. -The function X509V3_get_d2i() will return B if the extension is not +The function X509V3_get_d2i() and its variants +will return B if the extension is not found, occurs multiple times or cannot be decoded. It is possible to determine the precise reason by checking the value of B<*crit>. @@ -195,17 +197,17 @@ The following extensions are used by certificate transparency, RFC6962 =head1 RETURN VALUES -X509V3_EXT_d2i() and *X509V3_get_d2i() return a pointer to an extension -specific structure or B if an error occurs. +X509V3_get_d2i(), its variants, and X509V3_EXT_d2i() return +a pointer to an extension specific structure or B if an error occurs. -X509V3_EXT_i2d() returns a pointer to an B structure -or B if an error occurs. - -X509V3_add1_i2d() returns 1 if the operation is successful and 0 if it -fails due to a non-fatal error (extension not found, already exists, +X509V3_add1_i2d() and its variants return 1 if the operation is successful +and 0 if it fails due to a non-fatal error (extension not found, already exists, cannot be encoded) or -1 due to a fatal error such as a memory allocation failure. +X509V3_EXT_i2d() returns a pointer to an B structure +or B if an error occurs. + X509_get0_extensions(), X509_CRL_get0_extensions() and X509_REVOKED_get0_extensions() return a stack of extensions. They return NULL if no extensions are present.