]> git.baikalelectronics.ru Git - kernel.git/commit
net: sched: sch: Fix off by one in htb_activate_prios()
authorDan Carpenter <error27@gmail.com>
Mon, 6 Feb 2023 13:18:32 +0000 (16:18 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Feb 2023 11:50:42 +0000 (12:50 +0100)
commitfcea33c80f8814ae373b4bf96027878bcf2b6a2e
treec92138d3b6d29affc8a07c97efeed4b73d006153
parent36e2aa79e69c7a936f9aacd76f1e635d1399ca4d
net: sched: sch: Fix off by one in htb_activate_prios()

commit 9cec2aaffe969f2a3e18b5ec105fc20bb908e475 upstream.

The > needs be >= to prevent an out of bounds access.

Fixes: de5ca4c3852f ("net: sched: sch: Bounds check priority")
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Reviewed-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/Y+D+KN18FQI2DKLq@kili
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/sched/sch_htb.c