kernel-fxtec-pro1x/tools
Jason A. Donenfeld 33fa89ac6b UPSTREAM: wireguard: device: avoid circular netns references
Before, we took a reference to the creating netns if the new netns was
different. This caused issues with circular references, with two
wireguard interfaces swapping namespaces. The solution is to rather not
take any extra references at all, but instead simply invalidate the
creating netns pointer when that netns is deleted.

In order to prevent this from happening again, this commit improves the
rough object leak tracking by allowing it to account for created and
destroyed interfaces, aside from just peers and keys. That then makes it
possible to check for the object leak when having two interfaces take a
reference to each others' namespaces.

Fixes: e7096c131e51 ("net: WireGuard secure network tunnel")
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 900575aa33a3eaaef802b31de187a85c4a4b4bd0)
Bug: 152722841
[Jason: netlink notifier uses exit instead of pre_exit]
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: Iea52fe3ca0e41318c392d9e91edb1856de6c9528
2020-10-25 13:40:24 +01:00
..
accounting This is the 4.19.115 stable release 2020-04-13 13:09:17 +02:00
arch jump_label: move 'asm goto' support test to Kconfig 2019-06-04 08:02:34 +02:00
bpf bpftool: Fix printing incorrect pointer in btf_dump_ptr 2020-04-29 16:31:07 +02:00
build tools build feature: Quote CC and CXX for their arguments 2020-08-21 11:05:39 +02:00
cgroup tools: fix cross-compile var clobbering 2018-02-21 15:35:42 -08:00
firewire
gpio tools: gpio-hammer: Avoid potential overflow in main 2020-10-01 13:14:39 +02:00
hv Tools: hv: kvp: eliminate 'may be used uninitialized' warning 2019-09-10 10:33:50 +01:00
iio iio: iio-utils: Fix possible incorrect mask calculation 2019-07-31 07:27:02 +02:00
include This is the 4.19.144 stable release 2020-09-09 19:48:58 +02:00
kvm/kvm_stat tools/kvm_stat: Fix kvm_exit filter name 2020-02-11 04:34:08 -08:00
laptop tools: fix cross-compile var clobbering 2018-02-21 15:35:42 -08:00
leds tools: fix cross-compile var clobbering 2018-02-21 15:35:42 -08:00
lib tools lib traceevent: Fix memory leak in process_dynamic_array_len 2020-08-11 15:32:33 +02:00
memory-model tools/memory-model: Rename litmus tests to comply to norm7 2018-07-17 09:30:36 +02:00
nfsd
objtool objtool: Fix noreturn detection for ignored functions 2020-10-01 13:14:50 +02:00
pci tools: PCI: Fix broken pcitest compilation 2019-11-24 08:21:08 +01:00
pcmcia
perf perf cs-etm: Move definition of 'traceid_list' global variable from header file 2020-10-17 10:12:56 +02:00
power tools/power/x86/intel_pstate_tracer: changes for python 3 compatibility 2020-10-01 13:14:31 +02:00
scripts tools: Let O= makes handle a relative path with -C option 2020-04-02 15:28:17 +02:00
spi tools: fix cross-compile var clobbering 2018-02-21 15:35:42 -08:00
testing UPSTREAM: wireguard: device: avoid circular netns references 2020-10-25 13:40:24 +01:00
thermal/tmon tools/thermal: tmon: fix for segfault 2018-03-27 09:51:23 +02:00
time
usb usbip: Fix unsafe unaligned pointer usage 2020-02-24 08:34:45 +01:00
virtio virtio: fix test build after uio.h change 2019-01-13 09:51:03 +01:00
vm tools/vm: fix cross-compile build 2020-04-29 16:31:28 +02:00
wmi tools: fix cross-compile var clobbering 2018-02-21 15:35:42 -08:00
Makefile