android_kernel_motorola_sm6375/drivers/nvdimm
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Dan Carpenter 436af737c3 libnvdimm: Out of bounds read in __nd_ioctl()
[ Upstream commit f84afbdd3a9e5e10633695677b95422572f920dc ]

The "cmd" comes from the user and it can be up to 255.  It it's more
than the number of bits in long, it results out of bounds read when we
check test_bit(cmd, &cmd_mask).  The highest valid value for "cmd" is
ND_CMD_CALL (10) so I added a compare against that.

Fixes: 62232e45f4 ("libnvdimm: control (ioctl) messages for nvdimm_bus and nvdimm devices")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Link: https://lore.kernel.org/r/20200225162055.amtosfy7m35aivxg@kili.mountain
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-04-23 10:36:42 +02:00
..
badrange.c
blk.c
btt.c libnvdimm/btt: fix variable 'rc' set but not used 2020-01-04 19:18:12 +01:00
btt.h
btt_devs.c
bus.c libnvdimm: Out of bounds read in __nd_ioctl() 2020-04-23 10:36:42 +02:00
claim.c
core.c
dax_devs.c
dimm.c
dimm_devs.c
e820.c
Kconfig
label.c
label.h
Makefile
namespace_devs.c libnvdimm: Fix endian conversion issues 2019-09-24 10:23:44 -07:00
nd-core.h
nd.h libnvdimm/dax: Pick the right alignment default when creating dax devices 2019-09-24 10:23:41 -07:00
nd_virtio.c
of_pmem.c
pfn.h
pfn_devs.c libnvdimm fixes v5.4-rc1 2019-09-29 10:33:41 -07:00
pmem.c
pmem.h
region.c libnvdimm/region: Initialize bad block for volatile namespaces 2019-09-24 10:27:51 -07:00
region_devs.c libnvdimm/region: Enable MAP_SYNC for volatile regions 2019-09-24 10:33:19 -07:00
security.c libnvdimm: prevent nvdimm from requesting key when security is disabled 2019-09-24 10:30:10 -07:00
virtio_pmem.c
virtio_pmem.h