linux_dsm_epyc7002/arch
Stephan Mueller 9c674e1e2f crypto: aesni - handle zero length dst buffer
GCM can be invoked with a zero destination buffer. This is possible if
the AAD and the ciphertext have zero lengths and only the tag exists in
the source buffer (i.e. a source buffer cannot be zero). In this case,
the GCM cipher only performs the authentication and no decryption
operation.

When the destination buffer has zero length, it is possible that no page
is mapped to the SG pointing to the destination. In this case,
sg_page(req->dst) is an invalid access. Therefore, page accesses should
only be allowed if the req->dst->length is non-zero which is the
indicator that a page must exist.

This fixes a crash that can be triggered by user space via AF_ALG.

CC: <stable@vger.kernel.org>
Signed-off-by: Stephan Mueller <smueller@chronox.de>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2018-01-26 01:10:32 +11:00
..
alpha
arc
arm crypto: hash - annotate algorithms taking optional key 2018-01-12 23:03:35 +11:00
arm64 crypto: arm64/sha1-ce - get rid of literal pool 2018-01-18 23:00:33 +11:00
blackfin
c6x
cris bpf: correct broken uapi for BPF_PROG_TYPE_PERF_EVENT program type 2017-12-05 15:02:40 +01:00
frv
h8300
hexagon
ia64
m32r
m68k Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-12-08 13:32:44 -08:00
metag
microblaze
mips Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-12-08 13:32:44 -08:00
mn10300
nios2
openrisc
parisc
powerpc crypto: hash - annotate algorithms taking optional key 2018-01-12 23:03:35 +11:00
riscv
s390 crypto: hash - annotate algorithms taking optional key 2018-01-12 23:03:35 +11:00
score
sh
sparc crypto: hash - annotate algorithms taking optional key 2018-01-12 23:03:35 +11:00
tile
um
unicore32
x86 crypto: aesni - handle zero length dst buffer 2018-01-26 01:10:32 +11:00
xtensa
.gitignore
Kconfig