CVE-2022-49873

bpf: Fix wrong reg type conversion in release_reference()

MEDIUM
5.5
CVSS Score
Published: May 1, 2025 at 02:10 PM UTC
Updated: June 17, 2026 at 05:19 AM UTC
1 product affected across 1 vendorLinux Kernel

Using Linux by Linux?

Get instant alerts when new vulnerabilities affect Linux - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
MEDIUM5.5
Exploit prediction
EPSS 0.2%
SSVC
No known exploit

Description

In the Linux kernel, the following vulnerability has been resolved: bpf: Fix wrong reg type conversion in release_reference() Some helper functions will allocate memory. To avoid memory leaks, the verifier requires the eBPF program to release these memories by calling the corresponding helper functions. When a resource is released, all pointer registers corresponding to the resource should be invalidated. The verifier use release_references() to do this job, by apply __mark_reg_unknown() to each relevant register. It will give these registers the type of SCALAR_VALUE. A register that will contain a pointer value at runtime, but of type SCALAR_VALUE, which may allow the unprivileged user to get a kernel pointer by storing this register into a map. Using __mark_reg_not_init() while NOT allow_ptr_leaks can mitigate this problem.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

4.20 ≤ v < 5.10.1554.20 ≤ v < 5.15.794.20 ≤ v < 6.0.94.20 ≤ v < 6.15.11 ≤ v < 5.15.795.16 ≤ v < 6.0.96.1 rc16.1 rc26.1 rc36.1 rc4fd978bf7fd312581a7ca454a991f0ffb34c4204b
Vendor states this is fixed in 466ce46f251dfb259a8cbaa895ab9edd6fb56240 (fixed)
Vendor states this is fixed in ae5ccad6c711db0f2ca1231be051935dd128b8f5 (fixed)
Vendor states this is fixed in cedd4f01f67be94735f15123158f485028571037 (fixed)
Vendor states this is fixed in f1db20814af532f85e091231223e5e4818e8464b (fixed)
Vendor states this is fixed in 4.20 (unaffected)
Vendor states this is fixed in 5.10.155 (unaffected)
Vendor states this is fixed in 5.15.79 (unaffected)
Vendor states this is fixed in 6.0.9 (unaffected)
Vendor states this is fixed in 6.1 (unaffected)

References (4)

Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/466ce46f251dfb259a8cbaa895ab9edd6fb56240
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/ae5ccad6c711db0f2ca1231be051935dd128b8f5
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/cedd4f01f67be94735f15123158f485028571037
Patch
Source: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
https://git.kernel.org/stable/c/f1db20814af532f85e091231223e5e4818e8464b

SSVC — Action Prioritization

SSVCNo known exploitNot automatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

5.5MEDIUMCISA-ADP
Attack Vector
LOCAL
Complexity
LOW
Privileges
LOW
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusMODIFIED
CWE
CWE-704

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card