CVE-2022-49970
BaseFortify
Publication date: 2025-06-18
Last updated on: 2026-01-23
Assigner: kernel.org
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| linux | linux_kernel | From 5.10.138 (inc) to 5.10.142 (exc) |
| linux | linux_kernel | From 5.15.61 (inc) to 5.15.66 (exc) |
| linux | linux_kernel | From 5.18.18 (inc) to 5.19 (exc) |
| linux | linux_kernel | From 5.19.2 (inc) to 5.19.8 (exc) |
| linux | linux_kernel | 6.0 |
| linux | linux_kernel | 6.0 |
| linux | linux_kernel | 6.0 |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-NVD-CWE-noinfo |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
This vulnerability is a kernel BUG in the Linux kernel's BPF cgroup code, specifically in the purge_effective_progs function. It occurs when detaching BPF programs from cgroups under certain conditions involving multiple attached programs and memory allocation failures (kmalloc fail). The bug leads to a NULL pointer dereference due to incorrect handling of program iteration and flags, causing the kernel to crash.
How can this vulnerability impact me? :
This vulnerability can cause the Linux kernel to crash (kernel BUG) when detaching BPF programs from cgroups under specific conditions. Such crashes can lead to system instability, denial of service, and potential disruption of services running on affected systems.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability manifests as a kernel BUG triggered during detaching BPF programs from cgroups, which can be detected by monitoring kernel logs for messages similar to 'kernel BUG at kernel/bpf/cgroup.c:925!' or related stack traces involving __cgroup_bpf_detach. You can check kernel logs using commands like 'dmesg | grep -i "kernel BUG"' or 'journalctl -k | grep -i "cgroup_bpf_detach"'. Additionally, monitoring for crashes or oops messages related to BPF and cgroup operations can help detect this issue.
What immediate steps should I take to mitigate this vulnerability?
Immediate mitigation involves updating the Linux kernel to a version where this vulnerability is fixed, as the issue is resolved in the kernel code. Avoid detaching BPF programs from cgroups in the specific sequence that triggers the bug, especially when using fail-nth for failslab injection or similar testing. If updating is not immediately possible, restrict or monitor operations that attach or detach BPF programs to cgroups to prevent triggering the kernel BUG.