kernel_samsung_a53x/drivers/crypto
zhenwei pi aafb2c6302 crypto: virtio/akcipher - Fix stack overflow on memcpy
[ Upstream commit c0ec2a712daf133d9996a8a1b7ee2d4996080363 ]

sizeof(struct virtio_crypto_akcipher_session_para) is less than
sizeof(struct virtio_crypto_op_ctrl_req::u), copying more bytes from
stack variable leads stack overflow. Clang reports this issue by
commands:
make -j CC=clang-14 mrproper >/dev/null 2>&1
make -j O=/tmp/crypto-build CC=clang-14 allmodconfig >/dev/null 2>&1
make -j O=/tmp/crypto-build W=1 CC=clang-14 drivers/crypto/virtio/
  virtio_crypto_akcipher_algs.o

Fixes: 59ca6c93387d ("virtio-crypto: implement RSA algorithm")
Link: https://lore.kernel.org/all/0a194a79-e3a3-45e7-be98-83abd3e1cb7e@roeck-us.net/
Cc: <stable@vger.kernel.org>
Signed-off-by: zhenwei pi <pizhenwei@bytedance.com>
Tested-by: Nathan Chancellor <nathan@kernel.org> # build
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-18 23:18:28 +01:00
..
allwinner
amcc
amlogic
axis
bcm
caam crypto: caam/jr - fix Chacha20 + Poly1305 self test failure 2024-11-18 11:43:03 +01:00
cavium
ccp crypto: ccp - Fix null pointer dereference in __sev_platform_shutdown_locked 2024-11-18 12:13:32 +01:00
ccree
chelsio
fmp
fmp_simulator
hisilicon
inside-secure
marvell
mediatek
nx
qat crypto: qat - increase size of buffers 2024-11-18 11:43:03 +01:00
qce
rockchip
stm32 crypto: stm32/crc32 - fix parsing list of devices 2024-11-18 12:13:10 +01:00
ux500
virtio crypto: virtio/akcipher - Fix stack overflow on memcpy 2024-11-18 23:18:28 +01:00
vmx
xilinx
atmel-aes-regs.h
atmel-aes.c
atmel-authenc.h
atmel-ecc.c
atmel-i2c.c
atmel-i2c.h
atmel-sha-regs.h
atmel-sha.c
atmel-sha204a.c
atmel-tdes-regs.h
atmel-tdes.c
exynos-rng.c
geode-aes.c
geode-aes.h
hifn_795x.c
img-hash.c
ixp4xx_crypto.c
Kconfig
Makefile
mxs-dcp.c
n2_asm.S
n2_core.c
n2_core.h
omap-aes-gcm.c
omap-aes.c
omap-aes.h
omap-crypto.c
omap-crypto.h
omap-des.c
omap-sham.c
padlock-aes.c
padlock-sha.c
picoxcell_crypto.c
picoxcell_crypto_regs.h
qcom-rng.c
s5p-sss.c
sa2ul.c crypto: sa2ul - Return crypto_aead_setkey to transfer the error 2024-11-18 12:12:26 +01:00
sa2ul.h
sahara.c crypto: sahara - do not resize req->src when doing hash operations 2024-11-18 12:12:27 +01:00
talitos.c
talitos.h