CVE-2022-50223
BaseFortify
Publication date: 2025-06-18
Last updated on: 2025-11-19
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.15.160 (inc) to 5.16 (inc) |
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 warning issue in the Linux kernel for the LoongArch architecture. When certain kernel configuration options (CONFIG_CPUMASK_OFFSTACK and CONFIG_DEBUG_PER_CPU_MAPS) are enabled, a runtime warning is generated while displaying CPU information (/proc/cpuinfo). The warning occurs because the code uses a fixed CPU limit (NR_CPUS) instead of the actual runtime CPU limit (nr_cpu_ids) to iterate over CPUs, which can cause incorrect behavior or warnings.
How can this vulnerability impact me? :
The impact of this vulnerability is primarily that it causes runtime warnings in the kernel logs when viewing CPU information. It does not indicate a security breach or system compromise but may cause confusion or concern due to the warning messages. It does not appear to cause crashes or data loss.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by checking the system logs for runtime warnings related to cpu_max_bits_warn() when showing /proc/cpuinfo. Specifically, look for kernel warning messages similar to the following in the dmesg or kernel log output: "WARNING: CPU: <cpu_id> PID: <pid> at include/linux/cpumask.h:108 show_cpuinfo+0x5e8/0x5f0" You can use the command `dmesg | grep -i 'WARNING: CPU'` or `journalctl -k | grep -i 'WARNING: CPU'` to find such warnings.
What immediate steps should I take to mitigate this vulnerability?
To mitigate this vulnerability, update the Linux kernel to a version where the issue is fixed. The fix involves using nr_cpu_ids instead of NR_CPUS to iterate CPUs when CONFIG_CPUMASK_OFFSTACK and CONFIG_DEBUG_PER_CPU_MAPS are selected. Applying the patch or upgrading to a kernel version that includes this fix will prevent the runtime warning and potential related issues.