From 2fec05364409258a28a77ede1552f1cdc3eabd24 Mon Sep 17 00:00:00 2001 From: David Phillips Date: Tue, 24 Apr 2018 14:02:34 +1200 Subject: Fix OOB access Thanks to alyptik for spotting this one --- cl/onion.cl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cl/onion.cl') diff --git a/cl/onion.cl b/cl/onion.cl index 4200859..66075a9 100644 --- a/cl/onion.cl +++ b/cl/onion.cl @@ -32,7 +32,7 @@ void sha_chunk(unsigned char (*buf)[SHA_CHUNK_LEN], struct sha_data *sha) { }; #pragma unroll - for (i = 0; i < 80; i++, bo+=4) { + for (i = 0; i < 16; i++, bo+=4) { w[i] = ((*buf)[bo]) << 24; w[i] |= ((*buf)[bo+1]) << 16; w[i] |= ((*buf)[bo+2]) << 8; -- cgit v1.1