app/eventdev: fix overflow in lcore list parsing
authorMin Hu (Connor) <humin29@huawei.com>
Fri, 23 Apr 2021 07:38:08 +0000 (15:38 +0800)
committerJerin Jacob <jerinj@marvell.com>
Thu, 29 Apr 2021 07:23:20 +0000 (09:23 +0200)
commit32d7dbf269be84cb906979d73ad81b40e28d377a
tree0edd5c0edc2d13fc60b22aaeb8f6d90e440296cc
parentcaec80f92adf21f86d18b77d4cdc951b41088c6e
app/eventdev: fix overflow in lcore list parsing

Tainted and unvalidated integer 'idx' used as an index, which may
lead to buffer overflow.

This patch fixed it.

Fixes: 89e5eb118017 ("app/testeventdev: add string parsing helpers")
Cc: stable@dpdk.org
Signed-off-by: Min Hu (Connor) <humin29@huawei.com>
Acked-by: Pavan Nikhilesh <pbhagavatula@marvell.com>
app/test-eventdev/evt_options.c
app/test-eventdev/parser.c
app/test-eventdev/parser.h