Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1360757 > unrolled thread

[PATCH] PKCS#7: fix missing break on OID_sha224 case

Started byColin King <colin.king@canonical.com>
First post2016-03-18 17:00 +0100
Last post2016-03-18 17:00 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel


Contents

  [PATCH] PKCS#7: fix missing break on OID_sha224 case Colin King <colin.king@canonical.com> - 2016-03-18 17:00 +0100

#1360757 — [PATCH] PKCS#7: fix missing break on OID_sha224 case

FromColin King <colin.king@canonical.com>
Date2016-03-18 17:00 +0100
Subject[PATCH] PKCS#7: fix missing break on OID_sha224 case
Message-ID<re4YH-Ni-49@gated-at.bofh.it>
From: Colin Ian King <colin.king@canonical.com>

The OID_sha224 case is missing a break and it falls through
to the -ENOPKG error default.  Since HASH_ALGO_SHA224 seems
to be supported, this looks like an unintentional missing break.

Fixes: 07f081fb5057 ("PKCS#7: Add OIDs for sha224, sha284 and sha512 hash algos and use them")
Cc: <stable@vger.kernel.org> # 4.2+
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 crypto/asymmetric_keys/pkcs7_parser.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/crypto/asymmetric_keys/pkcs7_parser.c b/crypto/asymmetric_keys/pkcs7_parser.c
index 40de03f..bdd0d753 100644
--- a/crypto/asymmetric_keys/pkcs7_parser.c
+++ b/crypto/asymmetric_keys/pkcs7_parser.c
@@ -237,6 +237,7 @@ int pkcs7_sig_note_digest_algo(void *context, size_t hdrlen,
 		break;
 	case OID_sha224:
 		ctx->sinfo->sig.hash_algo = "sha224";
+		break;
 	default:
 		printk("Unsupported digest algo: %u\n", ctx->last_oid);
 		return -ENOPKG;
-- 
2.7.3

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web