This is a note to let you know that I've just added the patch titled
crypto: sha512 - Fix byte counter overflow in SHA-512
to the 3.0-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
crypto-sha512-fix-byte-counter-overflow-in-sha-512.patch
and it can be found in the queue-3.0 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <[email protected]> know about it.
>From 25c3d30c918207556ae1d6e663150ebdf902186b Mon Sep 17 00:00:00 2001
From: Kent Yoder <[email protected]>
Date: Thu, 5 Apr 2012 20:34:20 +0800
Subject: crypto: sha512 - Fix byte counter overflow in SHA-512
From: Kent Yoder <[email protected]>
commit 25c3d30c918207556ae1d6e663150ebdf902186b upstream.
The current code only increments the upper 64 bits of the SHA-512 byte
counter when the number of bytes hashed happens to hit 2^64 exactly.
This patch increments the upper 64 bits whenever the lower 64 bits
overflows.
Signed-off-by: Kent Yoder <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
---
crypto/sha512_generic.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/crypto/sha512_generic.c
+++ b/crypto/sha512_generic.c
@@ -174,7 +174,7 @@ sha512_update(struct shash_desc *desc, c
index = sctx->count[0] & 0x7f;
/* Update number of bytes */
- if (!(sctx->count[0] += len))
+ if ((sctx->count[0] += len) < len)
sctx->count[1]++;
part_len = 128 - index;
Patches currently in stable-queue which might be from [email protected]
are
queue-3.0/crypto-sha512-fix-byte-counter-overflow-in-sha-512.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html