]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
log actual NID causing the 'unknown message digest algorithm error'
authorVladimír Kotal <vladimir.kotal@oracle.com>
Thu, 15 Jun 2023 15:03:21 +0000 (17:03 +0200)
committerPauli <pauli@openssl.org>
Sun, 18 Jun 2023 06:58:54 +0000 (16:58 +1000)
Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/21214)

crypto/asn1/a_verify.c

index a55f60d75728d6b5a22635b2726943680d15323a..8aae75ac134c7b7eae696a7a0f7aae99e8fef1e4 100644 (file)
@@ -180,8 +180,9 @@ int ASN1_item_verify_ctx(const ASN1_ITEM *it, const X509_ALGOR *alg,
             if (mdnid != NID_undef) {
                 type = EVP_get_digestbynid(mdnid);
                 if (type == NULL) {
-                    ERR_raise(ERR_LIB_ASN1,
-                              ASN1_R_UNKNOWN_MESSAGE_DIGEST_ALGORITHM);
+                    ERR_raise_data(ERR_LIB_ASN1,
+                                   ASN1_R_UNKNOWN_MESSAGE_DIGEST_ALGORITHM,
+                                   "nid=0x%x", mdnid);
                     goto err;
                 }
             }