commit | a3d21e2101ea690ee476d63ed221940e762a67e3 | [log] [tgz] |
---|---|---|
author | Adam Langley <agl@chromium.org> | Tue Jul 29 19:44:10 2014 -0700 |
committer | Adam Langley <agl@chromium.org> | Tue Jul 29 19:44:50 2014 -0700 |
tree | c4a64a1f73849ed9acdd215f5f711f6e5ef63009 | |
parent | 44dbcc080470e5a72a260450fd4464b3eb90dcde [diff] [blame] |
Fix copy in AES-KW. The AES-KW code from 93a3dcd57262f5bbd84adaa5565abb14f95d79ae would write 8 bytes past the end of the out buffer. https://code.google.com/p/chromium/issues/detail?id=398699 Change-Id: I6e1a2884790f69cdbefb59ed60d71459b7327b89
diff --git a/crypto/cipher/e_aes.c b/crypto/cipher/e_aes.c index 8caac70..03f9e28 100644 --- a/crypto/cipher/e_aes.c +++ b/crypto/cipher/e_aes.c
@@ -1224,7 +1224,7 @@ } memcpy(A, in, 8); - memmove(out, in + 8, in_len); + memmove(out, in + 8, in_len - 8); for (j = 5; j < 6; j--) { for (i = n; i > 0; i--) {