linux_dsm_epyc7002/drivers/nfc/pn533
Dan Carpenter db574a60c4 nfc: pn533: prevent potential memory corruption
[ Upstream commit ca4d4c34ae9aa5c3c0da76662c5e549d2fc0cc86 ]

If the "type_a->nfcid_len" is too large then it would lead to memory
corruption in pn533_target_found_type_a() when we do:

	memcpy(nfc_tgt->nfcid1, tgt_type_a->nfcid_data, nfc_tgt->nfcid1_len);

Fixes: c3b1e1e8a7 ("NFC: Export NFCID1 from pn533")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-05-14 09:50:32 +02:00
..
i2c.c nfc: No need to set .owner platform_driver_register 2020-01-14 11:58:11 -08:00
Kconfig treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
Makefile nfc: pn533: add UART phy driver 2019-10-29 21:05:26 -07:00
pn533.c nfc: pn533: prevent potential memory corruption 2021-05-14 09:50:32 +02:00
pn533.h nfc: pn533: pn533_phy_ops dev_[up, down] return int 2019-11-13 12:15:03 -08:00
uart.c nfc: pn533: pn533_phy_ops dev_[up, down] return int 2019-11-13 12:15:03 -08:00
usb.c nfc: pn533/usb.c: fix spelling of "functions" 2020-09-08 20:25:51 -07:00