android_kernel_oneplus_msm8998/net
Sean Tranchetti 9d6e6eebc3 af_key: unconditionally clone on broadcast
Attempting to avoid cloning the skb when broadcasting by inflating
the refcount with sock_hold/sock_put while under RCU lock is dangerous
and violates RCU principles. It leads to subtle race conditions when
attempting to free the SKB, as we may reference sockets that have
already been freed by the stack.

Unable to handle kernel paging request at virtual address 6b6b6b6b6b6c4b
[006b6b6b6b6b6c4b] address between user and kernel address ranges
Internal error: Oops: 96000004 [#1] PREEMPT SMP
task: fffffff78f65b380 task.stack: ffffff8049a88000
pc : sock_rfree+0x38/0x6c
lr : skb_release_head_state+0x6c/0xcc
Process repro (pid: 7117, stack limit = 0xffffff8049a88000)
Call trace:
	sock_rfree+0x38/0x6c
	skb_release_head_state+0x6c/0xcc
	skb_release_all+0x1c/0x38
	__kfree_skb+0x1c/0x30
	kfree_skb+0xd0/0xf4
	pfkey_broadcast+0x14c/0x18c
	pfkey_sendmsg+0x1d8/0x408
	sock_sendmsg+0x44/0x60
	___sys_sendmsg+0x1d0/0x2a8
	__sys_sendmsg+0x64/0xb4
	SyS_sendmsg+0x34/0x4c
	el0_svc_naked+0x34/0x38
Kernel panic - not syncing: Fatal exception

CRs-Fixed: 2251019
Change-Id: Ib3b01f941a34a7df61fe9445f746b7df33f4656a
Signed-off-by: Sean Tranchetti <stranche@codeaurora.org>
2018-11-19 10:44:45 -08:00
..
6lowpan
9p net/9p: Switch to wait_event_killable() 2017-11-30 08:37:25 +00:00
802
8021q vlan: also check phy_driver ts_info for vlan's real device 2018-04-13 19:50:25 +02:00
appletalk
atm net: atm: Fix potential Spectre v1 2018-05-16 10:06:51 +02:00
ax25 ax25: Fix segfault after sock connection timeout 2017-02-04 09:45:09 +01:00
batman-adv batman-adv: fix packet loss for broadcasted DHCP packets to a server 2018-05-30 07:49:06 +02:00
bluetooth Merge android-4.4.153 (5e24b4e) into msm-4.4 2018-08-28 17:28:39 +05:30
bridge This is the 4.4.152 stable release 2018-08-24 13:37:12 +02:00
caif net: caif: Fix a sleep-in-atomic bug in cfpkt_create_pfx 2017-07-05 14:37:14 +02:00
can can: af_can: canfd_rcv(): replace WARN_ONCE by pr_warn_once 2018-01-31 12:06:08 +01:00
ceph libceph: validate con->state at the top of try_write() 2018-05-02 07:53:42 -07:00
core Merge "Merge android-4.4.153 (5e24b4e) into msm-4.4" 2018-09-06 14:14:24 -07:00
dcb
dccp dccp: fix undefined behavior with 'cwnd' shift in ccid2_cwnd_restart() 2018-08-22 07:48:35 +02:00
decnet dn_getsockoptdecnet: move nf_{get/set}sockopt outside sock lock 2018-02-25 11:03:38 +01:00
dns_resolver KEYS: DNS: fix parsing multiple options 2018-07-22 14:25:54 +02:00
dsa net: dsa: Do not suspend/resume closed slave_dev 2018-08-06 16:24:41 +02:00
ethernet net: introduce device min_header_len 2017-02-18 16:39:27 +01:00
hsr
ieee802154 net: ieee802154: fix net_device reference release too early 2018-04-13 19:50:10 +02:00
ipc_router net: ipc_router: Initialize the sockaddr in recvmsg() handler 2018-07-25 22:57:06 -07:00
ipv4 Merge android-4.4.153 (5e24b4e) into msm-4.4 2018-08-28 17:28:39 +05:30
ipv6 Merge android-4.4.153 (5e24b4e) into msm-4.4 2018-08-28 17:28:39 +05:30
ipx ipx: call ipxitf_put() in ioctl error path 2017-05-25 14:30:13 +02:00
irda irda: do not leak initialized list.dev to userspace 2017-08-30 10:19:21 +02:00
iucv net/iucv: Free memory obtained by kzalloc 2018-03-31 18:12:33 +02:00
key af_key: unconditionally clone on broadcast 2018-11-19 10:44:45 -08:00
l2tp This is the 4.4.151 stable release 2018-08-22 08:08:40 +02:00
l3mdev
lapb
llc llc: use refcount_inc_not_zero() for llc_sap_find() 2018-08-22 07:48:35 +02:00
mac80211 Merge android-4.4.132 (46155cc) into msm-4.4 2018-05-22 15:23:13 +05:30
mac802154
mpls mpls, nospec: Sanitize array index in mpls_label_ok() 2018-03-11 16:19:47 +01:00
netfilter Merge android-4.4.153 (5e24b4e) into msm-4.4 2018-08-28 17:28:39 +05:30
netlabel netlabel: If PF_INET6, check sk_buff ip header version 2018-05-30 07:49:17 +02:00
netlink Merge android-4.4.148 (f057ff9) into msm-4.4 2018-08-24 00:07:01 +05:30
netrom
nfc This is the 4.4.143 stable release 2018-07-31 20:11:21 +02:00
openvswitch openvswitch: Don't swap table in nlattr_set() after OVS_ATTR_NESTED is found 2018-05-26 08:48:47 +02:00
packet packet: refine ring v3 block size test to hold one frame 2018-08-24 13:27:01 +02:00
phonet
rds rds: avoid unenecessary cong_update in loop transport 2018-07-22 14:25:54 +02:00
rfkill This is the 4.4.132 stable release 2018-05-16 11:32:47 +02:00
rmnet_data net: rmnet_data: Support recycling frames to real device 2017-10-31 10:59:13 -06:00
rose
rxrpc rxrpc: check return value of skb_to_sgvec always 2018-04-13 19:50:23 +02:00
sched Merge android-4.4.153 (5e24b4e) into msm-4.4 2018-08-28 17:28:39 +05:30
sctp sctp: delay the authentication for the duplicated cookie-echo chunk 2018-05-26 08:48:49 +02:00
sunrpc rpc_pipefs: fix double-dput() 2018-04-24 09:32:11 +02:00
switchdev
tipc tipc: add policy for TIPC_NLA_NET_ADDR 2018-04-29 07:50:06 +02:00
unix Merge android-4.4.99 (7eab308) into msm-4.4 2017-12-26 17:37:19 +05:30
vmw_vsock vsock: split dwork to avoid reinitializations 2018-08-22 07:48:35 +02:00
wimax
wireless Merge "nl80211: nl80211_update_ft_ies to validate NL80211_ATTR_IE" 2018-09-05 04:32:31 -07:00
x25 net: x25: fix one potential use-after-free issue 2018-04-13 19:50:07 +02:00
xfrm xfrm: validate template mode 2018-10-29 09:15:20 -07:00
compat.c net: support compat 64-bit time in {s,g}etsockopt 2018-05-26 08:48:47 +02:00
Kconfig Merge android-4.4.118 (5f7f76a) into msm-4.4 2018-03-01 17:20:34 +05:30
Makefile
socket.c Merge android-4.4.153 (5e24b4e) into msm-4.4 2018-08-28 17:28:39 +05:30
sysctl_net.c