From: Jeffrey Walton Date: Sun, 29 Jun 2014 22:34:21 +0000 (+0100) Subject: Clarified that the signature's buffer size, `s`, is not used as an X-Git-Tag: OpenSSL_1_0_0n~50 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=b38db8803f69e6cff24126855ac80a60123492a6;p=oweals%2Fopenssl.git Clarified that the signature's buffer size, `s`, is not used as an IN parameter. Under the old docs, the only thing stated was "at most EVP_PKEY_size(pkey) bytes will be written". It was kind of misleading since it appears EVP_PKEY_size(pkey) WILL be written regardless of the signature's buffer size. (cherry picked from commit 6e6ba36d980f67b6e5c7b139f78da7acbbf8ec76) --- diff --git a/doc/crypto/EVP_SignInit.pod b/doc/crypto/EVP_SignInit.pod index 620a623ab6..14ecc775af 100644 --- a/doc/crypto/EVP_SignInit.pod +++ b/doc/crypto/EVP_SignInit.pod @@ -30,9 +30,11 @@ signature context B. This function can be called several times on the same B to include additional data. EVP_SignFinal() signs the data in B using the private key B and -places the signature in B. The number of bytes of data written (i.e. the -length of the signature) will be written to the integer at B, at most -EVP_PKEY_size(pkey) bytes will be written. +places the signature in B. B must be at least EVP_PKEY_size(pkey) +bytes in size. B is an OUT paramter, and not used as an IN parameter. +The number of bytes of data written (i.e. the length of the signature) +will be written to the integer at B, at most EVP_PKEY_size(pkey) bytes +will be written. EVP_SignInit() initializes a signing context B to use the default implementation of digest B.