diff options
Diffstat (limited to 'secure/lib/libcrypto/man/man3/EVP_PKEY_get_default_digest_nid.3')
-rw-r--r-- | secure/lib/libcrypto/man/man3/EVP_PKEY_get_default_digest_nid.3 | 52 |
1 files changed, 33 insertions, 19 deletions
diff --git a/secure/lib/libcrypto/man/man3/EVP_PKEY_get_default_digest_nid.3 b/secure/lib/libcrypto/man/man3/EVP_PKEY_get_default_digest_nid.3 index ebf7259a605d..a67894f3d43b 100644 --- a/secure/lib/libcrypto/man/man3/EVP_PKEY_get_default_digest_nid.3 +++ b/secure/lib/libcrypto/man/man3/EVP_PKEY_get_default_digest_nid.3 @@ -1,4 +1,4 @@ -.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) +.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.42) .\" .\" Standard preamble: .\" ======================================================================== @@ -68,8 +68,6 @@ . \} .\} .rr rF -.\" -.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ @@ -132,40 +130,56 @@ .rm #[ #] #H #V #F C .\" ======================================================================== .\" -.IX Title "EVP_PKEY_GET_DEFAULT_DIGEST_NID 3" -.TH EVP_PKEY_GET_DEFAULT_DIGEST_NID 3 "2022-06-21" "1.1.1p" "OpenSSL" +.IX Title "EVP_PKEY_GET_DEFAULT_DIGEST_NID 3ossl" +.TH EVP_PKEY_GET_DEFAULT_DIGEST_NID 3ossl "2023-09-19" "3.0.11" "OpenSSL" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" -EVP_PKEY_get_default_digest_nid \- get default signature digest +EVP_PKEY_get_default_digest_nid, EVP_PKEY_get_default_digest_name +\&\- get default signature digest .SH "SYNOPSIS" .IX Header "SYNOPSIS" -.Vb 2 +.Vb 1 \& #include <openssl/evp.h> +\& +\& int EVP_PKEY_get_default_digest_name(EVP_PKEY *pkey, +\& char *mdname, size_t mdname_sz); \& int EVP_PKEY_get_default_digest_nid(EVP_PKEY *pkey, int *pnid); .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" -The \fBEVP_PKEY_get_default_digest_nid()\fR function sets \fBpnid\fR to the default -message digest \s-1NID\s0 for the public key signature operations associated with key -\&\fBpkey\fR. Note that some signature algorithms (i.e. Ed25519 and Ed448) do not use -a digest during signing. In this case \fBpnid\fR will be set to NID_undef. +\&\fBEVP_PKEY_get_default_digest_name()\fR fills in the default message digest +name for the public key signature operations associated with key +\&\fIpkey\fR into \fImdname\fR, up to at most \fImdname_sz\fR bytes including the +ending \s-1NUL\s0 byte. The name could be \f(CW"UNDEF"\fR, signifying that a digest +must (for return value 2) or may (for return value 1) be left unspecified. +.PP +\&\fBEVP_PKEY_get_default_digest_nid()\fR sets \fIpnid\fR to the default message +digest \s-1NID\s0 for the public key signature operations associated with key +\&\fIpkey\fR. Note that some signature algorithms (i.e. Ed25519 and Ed448) +do not use a digest during signing. In this case \fIpnid\fR will be set +to NID_undef. This function is only reliable for legacy keys, which +are keys with a \fB\s-1EVP_PKEY_ASN1_METHOD\s0\fR; these keys have typically +been loaded from engines, or created with \fBEVP_PKEY_assign_RSA\fR\|(3) or +similar. .SH "NOTES" .IX Header "NOTES" -For all current standard OpenSSL public key algorithms \s-1SHA1\s0 is returned. +For all current standard OpenSSL public key algorithms \s-1SHA256\s0 is returned. .SH "RETURN VALUES" .IX Header "RETURN VALUES" -The \fBEVP_PKEY_get_default_digest_nid()\fR function returns 1 if the message digest -is advisory (that is other digests can be used) and 2 if it is mandatory (other -digests can not be used). It returns 0 or a negative value for failure. In -particular a return value of \-2 indicates the operation is not supported by the -public key algorithm. +\&\fBEVP_PKEY_get_default_digest_name()\fR and \fBEVP_PKEY_get_default_digest_nid()\fR +both return 1 if the message digest is advisory (that is other digests +can be used) and 2 if it is mandatory (other digests can not be used). +They return 0 or a negative value for failure. In particular a return +value of \-2 indicates the operation is not supported by the public key +algorithm. .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fBEVP_PKEY_CTX_new\fR\|(3), \&\fBEVP_PKEY_sign\fR\|(3), +\&\fBEVP_PKEY_digestsign_supports_digest\fR\|(3), \&\fBEVP_PKEY_verify\fR\|(3), \&\fBEVP_PKEY_verify_recover\fR\|(3), .SH "HISTORY" @@ -173,9 +187,9 @@ public key algorithm. This function was added in OpenSSL 1.0.0. .SH "COPYRIGHT" .IX Header "COPYRIGHT" -Copyright 2006\-2018 The OpenSSL Project Authors. All Rights Reserved. +Copyright 2006\-2023 The OpenSSL Project Authors. All Rights Reserved. .PP -Licensed under the OpenSSL license (the \*(L"License\*(R"). You may not use +Licensed under the Apache License 2.0 (the \*(L"License\*(R"). You may not use this file except in compliance with the License. You can obtain a copy in the file \s-1LICENSE\s0 in the source distribution or at <https://www.openssl.org/source/license.html>. |