]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commit
mmc: sdio: Check for CISTPL_VERS_1 buffer size
authorPali Rohár <pali@kernel.org>
Mon, 27 Jul 2020 13:38:34 +0000 (15:38 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Mon, 9 Nov 2020 13:49:10 +0000 (14:49 +0100)
commitf4c65801b1d01a0ff3f95a2eed6d71ebf27f74bf
tree80bf7a536f7a83a731712050e4ef9b84b1a8caf5
parent6288920da92269ecf80b419465cc976893ef2c82
mmc: sdio: Check for CISTPL_VERS_1 buffer size

BugLink: https://bugs.launchpad.net/bugs/1902115
[ Upstream commit 8ebe2607965d3e2dc02029e8c7dd35fbe508ffd0 ]

Before parsing CISTPL_VERS_1 structure check that its size is at least two
bytes to prevent buffer overflow.

Signed-off-by: Pali Rohár <pali@kernel.org>
Link: https://lore.kernel.org/r/20200727133837.19086-2-pali@kernel.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Ian May <ian.may@canonical.com>
drivers/mmc/core/sdio_cis.c