crypto: hisilicon/qm - increase the memory of local variables
authorKai Ye <yekai13@huawei.com>
Sat, 22 Oct 2022 01:17:44 +0000 (01:17 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 31 Dec 2022 12:33:05 +0000 (13:33 +0100)
commitfc521abb6ee4b8f06fdfc52646140dab6a2ed334
treed5fdfafaaddeaa327b3468e7de74002b63a135d5
parentfc80b877f1d0554d669395c776af24be968a290e
crypto: hisilicon/qm - increase the memory of local variables

[ Upstream commit 3efe90af4c0c46c58dba1b306de142827153d9c0 ]

Increase the buffer to prevent stack overflow by fuzz test. The maximum
length of the qos configuration buffer is 256 bytes. Currently, the value
of the 'val buffer' is only 32 bytes. The sscanf does not check the dest
memory length. So the 'val buffer' may stack overflow.

Signed-off-by: Kai Ye <yekai13@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/crypto/hisilicon/qm.c