linux_dsm_epyc7002/include/net/nfc
Dan Carpenter 6491d69839 nfc: nci: Potential off by one in ->pipes[] array
This is similar to commit e285d5bfb7 ("NFC: Fix the number of pipes")
where we changed NFC_HCI_MAX_PIPES from 127 to 128.

As the comment next to the define explains, the pipe identifier is 7
bits long.  The highest possible pipe is 127, but the number of possible
pipes is 128.  As the code is now, then there is potential for an
out of bounds array access:

    net/nfc/nci/hci.c:297 nci_hci_cmd_received() warn: array off by one?
    'ndev->hci_dev->pipes[pipe]' '0-127 == 127'

Fixes: 11f54f2286 ("NFC: nci: Add HCI over NCI protocol support")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-04-06 15:05:07 -07:00
..
digital.h NFC: digital: Add support for NFC DEP Response Waiting Time 2016-07-11 02:01:14 +02:00
hci.h NFC: Fix the number of pipes 2018-09-18 19:55:01 -07:00
llc.h NFC: hci: delete unused nfc_llc_get_rx_head_tail_room() 2016-07-04 12:14:05 +02:00
nci_core.h nfc: nci: Potential off by one in ->pipes[] array 2019-04-06 15:05:07 -07:00
nci.h NFC: nfcmrvl: add i2c driver 2015-10-27 04:21:14 +01:00
nfc.h NFC: Add nfc_dbg() macro 2017-04-05 10:15:20 +02:00