X-Git-Url: https://git.openssl.org/?a=blobdiff_plain;f=doc%2Fman3%2Fd2i_X509.pod;h=36a5e8f6db96155889652008d5d7b789e7078ed5;hb=ed57f7f93508776b898e4c23b65d67f3479edaf1;hp=30e6ad0d8f1210e33d9ff702160fda85705b5bef;hpb=8869ad4a39f13307ab710c1c53d97a46e144aef0;p=openssl.git diff --git a/doc/man3/d2i_X509.pod b/doc/man3/d2i_X509.pod index 30e6ad0d8f..36a5e8f6db 100644 --- a/doc/man3/d2i_X509.pod +++ b/doc/man3/d2i_X509.pod @@ -325,7 +325,6 @@ i2d_POLICYQUALINFO, i2d_PROFESSION_INFO, i2d_PROXY_CERT_INFO_EXTENSION, i2d_PROXY_POLICY, -i2d_PublicKey, i2d_RSAPrivateKey, i2d_RSAPrivateKey_bio, i2d_RSAPrivateKey_fp, @@ -523,8 +522,8 @@ Represents the B structure defined in PKCS#1 and PKCS#7. d2i_TYPE(), d2i_TYPE_bio() and d2i_TYPE_fp() return a valid B structure or B if an error occurs. If the "reuse" capability has been used with -a valid structure being passed in via B, then the object is not freed in -the event of error but may be in a potentially invalid or inconsistent state. +a valid structure being passed in via B, then the object is freed in +the event of error and B<*a> is set to NULL. i2d_TYPE() returns the number of bytes successfully encoded or a negative value if an error occurs. @@ -605,9 +604,13 @@ happen. =head1 BUGS In some versions of OpenSSL the "reuse" behaviour of d2i_TYPE() when -B<*px> is valid is broken and some parts of the reused structure may -persist if they are not present in the new one. As a result the use -of this "reuse" behaviour is strongly discouraged. +B<*a> is valid is broken and some parts of the reused structure may +persist if they are not present in the new one. Additionally, in versions of +OpenSSL prior to 1.1.0, when the "reuse" behaviour is used and an error occurs +the behaviour is inconsistent. Some functions behaved as described here, while +some did not free B<*a> on error and did not set B<*a> to NULL. + +As a result of the above issues the "reuse" behaviour is strongly discouraged. i2d_TYPE() will not return an error in many versions of OpenSSL, if mandatory fields are not initialized due to a programming error