freebsd-nq/sys
Andrey V. Elsukov 322e5efda8 ipfw: fix possible data race between jump cache reading and updating.
Jump cache is used to reduce the cost of rule lookup for O_SKIPTO and
O_CALLRETURN actions. It uses rules chain id to check correctness of
cached value. But due to the possible race, there is the chance that
one thread can read invalid value. In some cases this can lead to out
of bounds access and panic.

Use thread fence operations to constrain the reordering of accesses.
Also rename jump_fast and jump_linear functions to jump_cached and
jump_lookup_pos respectively.

Submitted by:	Arseny Smalyuk
Reviewed by:	melifaro
Obtained from:	Yandex LLC
MFC after:	1 week
Sponsored by:	Yandex LLC
Differential Revision:	https://reviews.freebsd.org/D31484
2021-08-17 11:08:28 +03:00
..
amd64 kvm_clock: KVM paravirtual clock support 2021-08-14 15:57:54 +03:00
arm Fix a common typo in source code comments 2021-08-14 14:17:48 +02:00
arm64 Enable arm64 SError exceptions in the kernel 2021-08-12 08:53:06 +00:00
bsm Add fspacectl(2), vn_deallocate(9) and VOP_DEALLOCATE(9). 2021-08-05 23:20:42 +08:00
cam Fix a common typo in source code comments 2021-08-14 14:08:46 +02:00
cddl sys/cddl: remove extraneous semicolons 2021-08-16 10:29:44 -04:00
compat linux(4): Improve comment. 2021-08-13 11:36:42 +03:00
conf kvm_clock: KVM paravirtual clock support 2021-08-14 15:57:54 +03:00
contrib ipfilter: remove doubled semicolons 2021-08-16 13:16:42 -04:00
crypto Use arm64 sha256 intrinsics in libmd 2021-08-11 10:20:48 +00:00
ddb fix style nit: space after if 2021-05-05 15:26:09 -06:00
dev sdhci_xenon: remove redundant code in property parsing 2021-08-17 09:03:45 +02:00
dts Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights 2021-08-08 10:42:24 -04:00
fs nfsd: Fix sanity check for NFSv4.2 Allocate operations 2021-08-12 16:48:28 -07:00
gdb
geom geom_disk: Add KMSAN checks 2021-08-11 16:33:41 -04:00
gnu
i386 kvm_clock: KVM paravirtual clock support 2021-08-14 15:57:54 +03:00
isa newbus: Move from bus_child_{pnpinfo,location}_src to bus_child_{pnpinfo,location} with sbuf 2021-06-22 20:52:06 -06:00
kern sigtimedwait: Use a unique wait channel for sleeping 2021-08-16 15:11:15 -04:00
kgssapi
libkern arc4random: Avoid KMSAN false positives from pre-seeding results 2021-08-13 09:58:42 -04:00
mips Fix a common typo in source code comments 2021-08-14 14:08:46 +02:00
modules enetc: Add autogenerated files to Makefile 2021-08-08 22:27:16 +02:00
net ether: Add a KMSAN check for transmitted frames 2021-08-11 16:33:41 -04:00
net80211 Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights 2021-08-08 10:42:24 -04:00
netgraph Fix a few typos in source code comments 2021-08-14 09:39:17 +02:00
netinet ip_reass: do less work in ipreass_slowtimo if possible 2021-08-14 18:50:12 +02:00
netinet6 frag6: do less work in frag6_slowtimo if possible 2021-08-14 18:51:00 +02:00
netipsec ipsec: fix race condition in key.c 2021-08-13 12:52:38 +02:00
netpfil ipfw: fix possible data race between jump cache reading and updating. 2021-08-17 11:08:28 +03:00
netsmb netsmb: Avoid a read-after-free in smb_t2_request_int() 2021-05-26 10:45:40 -04:00
nfs
nfsclient
nfsserver
nlm
ofed ibcore: Kernel space update based on Linux 5.7-rc1. 2021-07-28 13:28:29 +02:00
opencrypto Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights 2021-08-08 10:42:24 -04:00
powerpc powerpc/pseries: Allow radix pmap in pseries for ISA 3.0 2021-08-11 19:07:04 -05:00
riscv riscv: Fix pmap_alloc_l2 when it should allocate a new L1 entry 2021-08-09 20:28:37 +01:00
rpc rpc: Make function tables const 2021-08-14 11:26:12 -04:00
security Add fspacectl(2), vn_deallocate(9) and VOP_DEALLOCATE(9). 2021-08-05 23:20:42 +08:00
sys bitstring(3): Add bitstring traversal macros. 2021-08-16 23:24:05 +03:00
teken
tests routing: add IPv6 fib validation procedure. 2021-08-16 23:04:01 +00:00
tools Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights 2021-08-08 10:42:24 -04:00
ufs ufs rename: ensure that the result of ufs_checkpath() is stable 2021-08-13 17:52:26 +03:00
vm Fix a few typos in source code comments 2021-08-14 09:06:09 +02:00
x86 pvclock: Add vDSO support 2021-08-14 15:57:54 +03:00
xdr
xen xen: introduce xen_pv_disks_disabled() 2021-07-28 17:27:04 +02:00
Makefile