CVE-2022-49698·Kernel vulnerability
In the Linux kernel, the following vulnerability has been resolved: netfilter: use get_random_u32 instead of prandom bh might occur while updating per-cpu rnd_state from user context, ie. local_out path. BUG: using smp_processor_id() in preemptible [00000000] code: nginx/2725 caller is nft_ng_random_eval+0x24/0x54 [nft_numgen] Call Trace: check_preemption_disabled+0xde/0xe0 nft_ng_random_eval+0x24/0x54 [nft_numgen] Use the random driver instead, this also avoids need for local prandom state. Moreover, prandom now uses the random driver since d4150779e60f ("random32: use real rng for non-deterministic randomness"). Based on earlier patch from Pablo Neira.
- Severity
- high
- Software
- Kernel
- Fixed in
- 5.18.8
- Published
- 2025-02-26
Affected versions
From: 5.16
Until: 5.18.8
Fixed in: 5.18.8
How to fix this CVE
Update your Linux kernel to version 5.18.8 or later to address a race condition in the netfilter random number generation function that could cause kernel preemption issues. This vulnerability affects kernels from 5.16 through 5.18.7 and has been resolved by replacing unsafe per-CPU random state access with the kernel's cryptographic random driver.
sudo dnf update kernel kernel-develDefensia detects this vulnerability
How to check if you are affected
- Check your current kernel version: uname -r
- Verify if your kernel version is between 5.16 and 5.18.7: if your output shows 5.16.x through 5.18.7, you are vulnerable
- Search for preemption warnings in kernel logs related to nft_ng_random_eval: grep -i 'nft_ng_random_eval\|preemption' /var/log/kern.log or dmesg
- After patching, confirm the new kernel version is running: uname -r (should be 5.18.8 or higher, or a distribution-provided backport version)
FAQ
What is CVE-2022-49698?
This is a kernel race condition in netfilter's random number generation where unsafe per-CPU random state updates from userspace contexts could trigger preemption warnings and potential kernel instability. The vulnerability was introduced by improper use of the deprecated prandom API.
Is CVE-2022-49698 being actively exploited?
No, this vulnerability is not listed on the CISA Known Exploited Vulnerabilities catalog and no public exploits are available. It is primarily a kernel stability and reliability issue rather than a direct privilege escalation vector.
What versions of Kernel are affected by CVE-2022-49698?
Linux kernel versions 5.16 through 5.18.7 are affected. Version 5.18.8 and later contain the fix.
How do I check if my server is vulnerable to CVE-2022-49698?
Run 'uname -r' to get your kernel version. If it shows a version between 5.16 and 5.18.7 (inclusive), your system is vulnerable and should be updated immediately.
Does Defensia detect CVE-2022-49698?
Yes — Defensia's CVE advisory scanner compares installed package versions against the NVD database. If the Linux kernel is installed on a monitored server, CVE-2022-49698 will appear in your dashboard with remediation steps.
Related Kernel CVEs
References
Track CVEs across your fleet automatically
Defensia scans your Linux servers and tells you exactly which ones are running vulnerable versions — including CVE-2022-49698. Free for 1 server.
Get started free