kernel_optimize_test/net
Liu Jian 886eeb0460 bpf: Enlarge offset check value to INT_MAX in bpf_skb_{load,store}_bytes
commit 45969b4152c1752089351cd6836a42a566d49bcf upstream.

The data length of skb frags + frag_list may be greater than 0xffff, and
skb_header_pointer can not handle negative offset. So, here INT_MAX is used
to check the validity of offset. Add the same change to the related function
skb_store_bytes.

Fixes: 05c74e5e53 ("bpf: add bpf_skb_load_bytes helper")
Signed-off-by: Liu Jian <liujian56@huawei.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Song Liu <songliubraving@fb.com>
Link: https://lore.kernel.org/bpf/20220416105801.88708-2-liujian56@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-06 08:42:45 +02:00
..
6lowpan
9p xen/9p: use alloc/free_pages_exact() 2022-03-11 12:11:54 +01:00
802
8021q
appletalk
atm
ax25 ax25: Fix UAF bugs in ax25 timers 2022-04-20 09:23:32 +02:00
batman-adv batman-adv: Don't skb_split skbuffs with frag_list 2022-05-18 10:23:42 +02:00
bluetooth Bluetooth: Fix the creation of hdev->name 2022-05-15 20:00:09 +02:00
bpf
bpfilter
bridge net: bridge: Clear offload_fwd_mark when passing frame up bridge interface. 2022-05-25 09:17:59 +02:00
caif
can can: isotp: remove re-binding of bound socket 2022-05-12 12:25:35 +02:00
ceph libceph: fix potential use-after-free on linger ping and resends 2022-05-25 09:17:56 +02:00
core bpf: Enlarge offset check value to INT_MAX in bpf_skb_{load,store}_bytes 2022-06-06 08:42:45 +02:00
dcb net: dcb: disable softirqs in dcbnl_flush_dev() 2022-03-08 19:09:37 +01:00
dccp
decnet
dns_resolver
dsa net: dsa: Add missing of_node_put() in dsa_port_link_register_of 2022-05-09 09:05:02 +02:00
ethernet
ethtool
hsr
ieee802154 net: ieee802154: Return meaningful error codes from the netlink helpers 2022-02-08 18:30:37 +01:00
ife
ipv4 secure_seq: use the 64 bits of the siphash for port offset calculation 2022-05-30 09:33:23 +02:00
ipv6 secure_seq: use the 64 bits of the siphash for port offset calculation 2022-05-30 09:33:23 +02:00
iucv
kcm
key net: af_key: check encryption module availability consistency 2022-06-06 08:42:40 +02:00
l2tp
l3mdev l3mdev: l3mdev_master_upper_ifindex_by_index_rcu should be using netdev_master_upper_dev_get_rcu 2022-04-27 13:53:50 +02:00
lapb
llc llc: only change llc->dev when bind() succeeds 2022-03-28 09:57:10 +02:00
mac80211 mac80211: fix rx reordering with non explicit / psmp ack policy 2022-05-25 09:18:00 +02:00
mac802154
mpls
mptcp
ncsi
netfilter netfilter: nf_tables: sanitize nft_set_desc_concat_parse() 2022-06-06 08:42:42 +02:00
netlabel netlabel: fix out-of-bounds memory accesses 2022-04-13 21:01:00 +02:00
netlink netlink: do not reset transport header in netlink_recvmsg() 2022-05-18 10:23:43 +02:00
netrom
nfc NFC: nci: fix sleep in atomic context bugs caused by nci_skb_alloc 2022-05-25 09:17:59 +02:00
nsh
openvswitch openvswitch: fix OOB access in reserve_sfa_size() 2022-04-27 13:53:55 +02:00
packet net/packet: fix packet_sock xmit return value checking 2022-04-27 13:53:50 +02:00
phonet
psample
qrtr
rds
rfkill
rose
rxrpc rxrpc: Restore removed timer deletion 2022-04-27 13:53:49 +02:00
sched net/sched: act_pedit: sanitize shift argument before usage 2022-05-25 09:17:58 +02:00
sctp sctp: check asoc strreset_chunk in sctp_generate_reconf_event 2022-05-09 09:05:03 +02:00
smc net/smc: non blocking recvmsg() return -EAGAIN when no data and signal_pending 2022-05-18 10:23:44 +02:00
strparser
sunrpc SUNRPC: Fix fall-through warnings for Clang 2022-05-18 10:23:49 +02:00
switchdev
tipc tipc: fix the timer expires after interval 100ms 2022-04-08 14:40:23 +02:00
tls tls: Fix context leak on tls_device_down 2022-05-18 10:23:45 +02:00
unix
vmw_vsock vsock: each transport cycles only on its own sockets 2022-03-23 09:13:27 +01:00
wimax
wireless cfg80211: set custom regdomain after wiphy registration 2022-06-06 08:42:41 +02:00
x25 net/x25: Fix null-ptr-deref caused by x25_disconnect 2022-04-08 14:40:30 +02:00
xdp
xfrm xfrm: rework default policy structure 2022-05-25 09:17:58 +02:00
compat.c
devres.c
Kconfig
Makefile
socket.c
sysctl_net.c