alistair23-linux/net/sched
Daniel Borkmann 32b2f4b196 sched: cls_flow: fix panic on filter replace
The following test case causes a NULL pointer dereference in cls_flow:

  tc filter add dev foo parent 1: handle 0x1 flow hash keys dst action ok
  tc filter replace dev foo parent 1: pref 49152 handle 0x1 \
            flow hash keys mark action drop

To be more precise, actually two different panics are fixed, the first
occurs because tcf_exts_init() is not called on the newly allocated
filter when we do a replace. And the second panic uncovered after that
happens since the arguments of list_replace_rcu() are swapped, the old
element needs to be the first argument and the new element the second.

Fixes: 70da9f0bf9 ("net: sched: cls_flow use RCU")
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: John Fastabend <john.r.fastabend@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-07-21 00:25:03 -07:00
..
act_api.c net: sched: remove TC_MUNGED bits 2015-05-02 22:25:17 -04:00
act_bpf.c tc: act_bpf: fix memory leak 2015-07-15 21:36:35 -07:00
act_connmark.c net: sched: act_connmark: don't zap skb->nfct 2015-04-29 14:56:40 -04:00
act_csum.c
act_gact.c
act_ipt.c
act_mirred.c net: sched: use counter to break reclassify loops 2015-05-13 15:08:14 -04:00
act_nat.c
act_pedit.c net: sched: remove TC_MUNGED bits 2015-05-02 22:25:17 -04:00
act_police.c
act_simple.c
act_skbedit.c
act_vlan.c
cls_api.c net: sched: fix call_rcu() race on classifier module unloads 2015-05-21 18:48:18 -04:00
cls_basic.c
cls_bpf.c sched: cls_bpf: fix panic on filter replace 2015-07-21 00:25:02 -07:00
cls_cgroup.c
cls_flow.c sched: cls_flow: fix panic on filter replace 2015-07-21 00:25:03 -07:00
cls_flower.c sched: cls_flower: fix panic on filter replace 2015-07-21 00:25:03 -07:00
cls_fw.c
cls_route.c
cls_rsvp.c
cls_rsvp.h
cls_rsvp6.c
cls_tcindex.c
cls_u32.c
em_canid.c
em_cmp.c
em_ipset.c net: sched: Simplify em_ipset_match 2015-06-18 21:14:28 +02:00
em_meta.c
em_nbyte.c
em_text.c
em_u32.c
ematch.c
Kconfig net: add CONFIG_NET_INGRESS to enable ingress filtering 2015-05-14 01:10:05 -04:00
Makefile tc: introduce Flower classifier 2015-05-13 15:19:48 -04:00
sch_api.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next 2015-06-24 16:49:49 -07:00
sch_atm.c
sch_blackhole.c
sch_cbq.c
sch_choke.c flow_dissect: use programable dissector in skb_flow_dissect and friends 2015-05-13 15:19:47 -04:00
sch_codel.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2015-05-13 14:31:43 -04:00
sch_drr.c
sch_dsmark.c
sch_fifo.c
sch_fq.c
sch_fq_codel.c fq_codel: fix return value of fq_codel_drop() 2015-07-15 21:36:35 -07:00
sch_generic.c
sch_gred.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2015-05-13 14:31:43 -04:00
sch_hfsc.c
sch_hhf.c sched: Call skb_get_hash_perturb in sch_hhf 2015-05-04 00:09:08 -04:00
sch_htb.c
sch_ingress.c net: sched: further simplify handle_ing 2015-05-11 11:10:35 -04:00
sch_mq.c
sch_mqprio.c
sch_multiq.c
sch_netem.c net: sched: deprecate enqueue_root() 2015-05-11 14:17:32 -04:00
sch_pie.c
sch_plug.c
sch_prio.c
sch_qfq.c pkt_sched: sch_qfq: remove redundant -if- control statement 2015-06-21 09:47:24 -07:00
sch_red.c
sch_sfb.c sched: Call skb_get_hash_perturb in sch_sfb 2015-05-04 00:09:08 -04:00
sch_sfq.c net_sched: fix a use-after-free in sfq 2015-07-15 21:36:34 -07:00
sch_tbf.c
sch_teql.c