]> git.baikalelectronics.ru Git - kernel.git/commit
sched: Avoid dereferencing skb pointer after child enqueue
authorToke Høiland-Jørgensen <toke@redhat.com>
Wed, 9 Jan 2019 16:09:42 +0000 (17:09 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 16 Jan 2019 04:12:00 +0000 (20:12 -0800)
commit277e407dd6ecc58dea6aafffe30290bd51fc0ae6
treec662d696e0bfe2ee2be86cbdf0da095d9d6389ba
parent5ef62d3afce5a64e4cbab847c5ea0b5df787ccac
sched: Avoid dereferencing skb pointer after child enqueue

Parent qdiscs may dereference the pointer to the enqueued skb after
enqueue. However, both CAKE and TBF call consume_skb() on the original skb
when splitting GSO packets, leading to a potential use-after-free in the
parent. Fix this by avoiding dereferencing the skb pointer after enqueueing
to the child.

Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/sch_cbs.c
net/sched/sch_drr.c
net/sched/sch_dsmark.c
net/sched/sch_hfsc.c
net/sched/sch_htb.c
net/sched/sch_prio.c
net/sched/sch_qfq.c
net/sched/sch_tbf.c