WSL2-Linux-Kernel/net/core
Guillaume Nault 4296adc3e3 net/core: check length before updating Ethertype in skb_mpls_{push,pop}
Openvswitch allows to drop a packet's Ethernet header, therefore
skb_mpls_push() and skb_mpls_pop() might be called with ethernet=true
and mac_len=0. In that case the pointer passed to skb_mod_eth_type()
doesn't point to an Ethernet header and the new Ethertype is written at
unexpected locations.

Fix this by verifying that mac_len is big enough to contain an Ethernet
header.

Fixes: fa4e0f8855 ("net/sched: fix corrupted L2 header with MPLS 'push' and 'pop' actions")
Signed-off-by: Guillaume Nault <gnault@redhat.com>
Acked-by: Davide Caratti <dcaratti@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-10-04 15:09:26 -07:00
..
Makefile
bpf_sk_storage.c bpf: Change uapi for bpf iterator map elements 2020-08-06 16:39:14 -07:00
datagram.c
datagram.h
dev.c net: core: add nested_level variable in net_device 2020-09-28 15:00:15 -07:00
dev_addr_lists.c net: core: add nested_level variable in net_device 2020-09-28 15:00:15 -07:00
dev_ioctl.c treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
devlink.c treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
drop_monitor.c treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
dst.c net: Correct the comment of dst_dev_put() 2020-09-10 13:28:57 -07:00
dst_cache.c
failover.c
fib_notifier.c
fib_rules.c fib: fix fib_rule_ops indirect call wrappers when CONFIG_IPV6=m 2020-09-08 20:09:08 -07:00
filter.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf 2020-09-15 19:26:21 -07:00
flow_dissector.c net/flow_dissector: add packet hash dissection 2020-07-24 15:23:31 -07:00
flow_offload.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-07-25 17:49:04 -07:00
gen_estimator.c
gen_stats.c
gro_cells.c
hwbm.c
link_watch.c
lwt_bpf.c
lwtunnel.c
neighbour.c net: neighbor: add fdb extended attribute 2020-06-24 14:36:33 -07:00
net-procfs.c
net-sysfs.c net: accept an empty mask in /sys/class/net/*/queues/rx-*/rps_cpus 2020-08-12 13:18:16 -07:00
net-sysfs.h
net-traces.c
net_namespace.c Revert "netns: don't disable BHs when locking "nsid_lock"" 2020-09-07 14:32:39 -07:00
netclassid_cgroup.c
netevent.c
netpoll.c net: disable netpoll on fresh napis 2020-08-26 16:16:39 -07:00
netprio_cgroup.c
page_pool.c
pktgen.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-09-03 18:50:48 -07:00
ptp_classifier.c
request_sock.c
rtnetlink.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2020-08-03 18:27:40 -07:00
scm.c fs: Add receive_fd() wrapper for __receive_fd() 2020-07-13 11:03:44 -07:00
secure_seq.c
skbuff.c net/core: check length before updating Ethertype in skb_mpls_{push,pop} 2020-10-04 15:09:26 -07:00
skmsg.c treewide: Use fallthrough pseudo-keyword 2020-08-23 17:36:59 -05:00
sock.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-09-03 18:50:48 -07:00
sock_diag.c
sock_map.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-07-11 00:46:00 -07:00
sock_reuseport.c udp: Copy has_conns in reuseport_grow(). 2020-07-21 15:31:02 -07:00
stream.c
sysctl_net_core.c bpf: Check correct cred for CAP_SYSLOG in bpf_dump_raw_ok() 2020-07-08 16:01:21 -07:00
timestamping.c
tso.c net: tso: add UDP segmentation support 2020-06-18 20:46:23 -07:00
utils.c
xdp.c bpf, xdp: Remove XDP_QUERY_PROG and XDP_QUERY_PROG_HW XDP commands 2020-07-25 20:37:02 -07:00