crypto/sha3
Michael Munday 5d647ca157 sha3: fix SHA-3 on s390x when using KIMD instruction
An illegal instruction would occur due to a bug in the way input
slices were rounded down in size to a multiple of the rate for a
given hash type. This would only occur when the Write function
was called with more than ~3KiB of data and the length of the data
was not a multiple of the rate.

Fixes golang/go#36459.

Change-Id: I621ef8d75602bcd59bb44491e17f721050001e6d
Reviewed-on: https://go-review.googlesource.com/c/crypto/+/213857
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Michael Munday <mike.munday@ibm.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2020-01-08 21:55:11 +00:00
..
testdata sha3: add cSHAKE support 2019-04-17 17:40:47 +00:00
doc.go all: fix typos 2018-10-29 02:12:03 +00:00
hashes.go sha3: add support for Keccak-512 2019-01-03 21:31:33 +00:00
hashes_generic.go sha3: add a space before +build in build tag comments 2019-09-07 12:14:10 +00:00
keccakf.go crypto/sha3: use the assembly optimized KeccakF on amd64 2016-09-13 20:24:05 +00:00
keccakf_amd64.go crypto/sha3: use the assembly optimized KeccakF on amd64 2016-09-13 20:24:05 +00:00
keccakf_amd64.s sha3: fix SP adjustment 2016-10-21 19:51:19 +00:00
register.go go.crypto/sha3: use the go1.4 tag to register the hash functions. 2014-09-03 16:08:25 -07:00
sha3.go sha3: align (*state).storage 2019-11-05 03:41:35 +00:00
sha3_s390x.go sha3: fix SHA-3 on s390x when using KIMD instruction 2020-01-08 21:55:11 +00:00
sha3_s390x.s sha3: add a space before +build in build tag comments 2019-09-07 12:14:10 +00:00
sha3_test.go sha3: fix bug in cSHAKE Clone() 2019-05-13 17:29:03 +00:00
shake.go sha3: fix bug in cSHAKE Clone() 2019-05-13 17:29:03 +00:00
shake_generic.go sha3: add a space before +build in build tag comments 2019-09-07 12:14:10 +00:00
xor.go sha3: align (*state).storage 2019-11-05 03:41:35 +00:00
xor_generic.go sha3: use unaligned reads and xors on x86 and x64 2015-01-12 22:01:33 +00:00
xor_unaligned.go sha3: align (*state).storage 2019-11-05 03:41:35 +00:00