]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Add an additional note to EVP_DigestSign() documentation
authorMatt Caswell <matt@openssl.org>
Fri, 8 Oct 2021 13:43:17 +0000 (14:43 +0100)
committerMatt Caswell <matt@openssl.org>
Fri, 22 Oct 2021 07:43:27 +0000 (08:43 +0100)
Clarify what happens if it fails. Make it clear that you can pass a NULL
"sig" buffer to get the "siglen".

Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/16789)

doc/man3/EVP_DigestSignInit.pod

index 87480144654c53a05fc755636026efdcdea96648..c8385949fb689f588a8ec2e45511dc5523b0d3cd 100644 (file)
@@ -130,7 +130,11 @@ written to I<siglen>.
 
 EVP_DigestSign() signs I<tbslen> bytes of data at I<tbs> and places the
 signature in I<sig> and its length in I<siglen> in a similar way to
-EVP_DigestSignFinal().
+EVP_DigestSignFinal(). In the event of a failure EVP_DigestSign() cannot be
+called again without reinitialising the EVP_MD_CTX. If I<sig> is NULL before the
+call then I<siglen> will be populated with the required size for the I<sig>
+buffer. If I<sig> is non-NULL before the call then I<siglen> should contain the
+length of the I<sig> buffer.
 
 =head1 RETURN VALUES