CVE-2022-48872
Severity CVSS v4.0:
Pending analysis
Type:
CWE-416
Use After Free
Publication date:
21/08/2024
Last modified:
06/09/2024
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
misc: fastrpc: Fix use-after-free race condition for maps<br />
<br />
It is possible that in between calling fastrpc_map_get() until<br />
map->fl->lock is taken in fastrpc_free_map(), another thread can call<br />
fastrpc_map_lookup() and get a reference to a map that is about to be<br />
deleted.<br />
<br />
Rewrite fastrpc_map_get() to only increase the reference count of a map<br />
if it&#39;s non-zero. Propagate this to callers so they can know if a map is<br />
about to be deleted.<br />
<br />
Fixes this warning:<br />
refcount_t: addition on 0; use-after-free.<br />
WARNING: CPU: 5 PID: 10100 at lib/refcount.c:25 refcount_warn_saturate<br />
...<br />
Call trace:<br />
refcount_warn_saturate<br />
[fastrpc_map_get inlined]<br />
[fastrpc_map_lookup inlined]<br />
fastrpc_map_create<br />
fastrpc_internal_invoke<br />
fastrpc_device_ioctl<br />
__arm64_sys_ioctl<br />
invoke_syscall
Impact
Base Score 3.x
7.00
Severity 3.x
HIGH
Vulnerable products and versions
| CPE | From | Up to |
|---|---|---|
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.1 (including) | 5.4.230 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.5 (including) | 5.10.165 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.11 (including) | 5.15.90 (excluding) |
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 5.16 (including) | 6.2 (excluding) |
| cpe:2.3:o:linux:linux_kernel:6.2:rc1:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:6.2:rc2:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:6.2:rc3:*:*:*:*:*:* | ||
| cpe:2.3:o:linux:linux_kernel:6.2:rc4:*:*:*:*:*:* |
To consult the complete list of CPE names with products and versions, see this page
References to Advisories, Solutions, and Tools
- https://git.kernel.org/stable/c/079c78c68714f7d8d58e66c477b0243b31806907
- https://git.kernel.org/stable/c/556dfdb226ce1e5231d8836159b23f8bb0395bf4
- https://git.kernel.org/stable/c/61a0890cb95afec5c8a2f4a879de2b6220984ef1
- https://git.kernel.org/stable/c/96b328d119eca7563c1edcc4e1039a62e6370ecb
- https://git.kernel.org/stable/c/b171d0d2cf1b8387c72c8d325c5d5746fa271e39



