summaryrefslogtreecommitdiff
path: root/crypto/hmac.c
diff options
context:
space:
mode:
authorPhil Carmody <ext-phil.2.carmody@nokia.com>2009-07-24 13:59:17 +0800
committerHerbert Xu <herbert@gondor.apana.org.au>2009-07-24 13:59:17 +0800
commitfc3e20a232128a3fa1d176afb224101b585249a6 (patch)
tree6e48488550597fa19fbd61f058196a6eea05ef63 /crypto/hmac.c
parent2e39ef1c2371cb5fbdd2bccf5d79bf7fc9ed0a48 (diff)
downloadlinux-crypto-fc3e20a232128a3fa1d176afb224101b585249a6.tar.gz
linux-crypto-fc3e20a232128a3fa1d176afb224101b585249a6.zip
crypto: aes - Undefined behaviour in crypto_aes_expand_key
It's undefined behaviour in C to write outside the bounds of an array. The key expansion routine takes a shortcut of creating 8 words at a time, but this creates 4 additional words which don't fit in the array. As everyone is hopefully now aware, GCC is at liberty to make any assumptions and optimisations it likes in situations where it can detect that UB has occured, up to and including nasal demons, and as the indices being accessed in the array are trivially calculable, it's rash to invite gcc to do take any liberties at all. Signed-off-by: Phil Carmody <ext-phil.2.carmody@nokia.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'crypto/hmac.c')
0 files changed, 0 insertions, 0 deletions