From: Dr. David von Oheimb Date: Mon, 2 Jun 2025 19:01:50 +0000 (+0200) Subject: m_sigver.c do_sigver_init(): add details to EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KE... X-Git-Tag: 4.0-PRE-CLANG-FORMAT-WEBKIT~525 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d270e8a2615639ebd9d96534f9aadea061605253;p=thirdparty%2Fopenssl.git m_sigver.c do_sigver_init(): add details to EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE Reviewed-by: Dmitry Belyavskiy Reviewed-by: Paul Dale (Merged from https://github.com/openssl/openssl/pull/28473) --- diff --git a/crypto/evp/m_sigver.c b/crypto/evp/m_sigver.c index 976401041a1..740b9d7387c 100644 --- a/crypto/evp/m_sigver.c +++ b/crypto/evp/m_sigver.c @@ -302,7 +302,9 @@ static int do_sigver_init(EVP_MD_CTX *ctx, EVP_PKEY_CTX **pctx, type = evp_get_digestbyname_ex(locpctx->libctx, mdname); if (ctx->pctx->pmeth == NULL) { - ERR_raise(ERR_LIB_EVP, EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE); + ERR_raise_data(ERR_LIB_EVP, EVP_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE, + ver ? "%s digest_verify_init" : "%s digest_sign_init", + EVP_PKEY_get0_type_name(locpctx->pkey)); return 0; }