Vulnerability in Kernel: mce: fix set_mce_nospec to always unmap the whole page

Kernel Updated 02 Oct 2025

Summary

28/06/2022
N/A
No i
Unrated
Not published

GSD-2022-1002705: mce: fix set_mce_nospec to always unmap the whole page. Affects Kernel versions >= 284ce4011ba60d6c487b668eea729b6294930806, < 49ca50a98b3676c64a1fd02dd23989247e50b7ae. No fix is published. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The Kernel is a critical component of the Linux operating system that acts as a bridge between the hardware and software layers. It provides essential functionalities and services to enable the proper functioning of the system. This vulnerability specifically affects the Kernel's 'mce' module, which is responsible for handling machine check exceptions (MCEs). MCEs are hardware-generated interrupts that indicate potential hardware errors or inconsistencies. The 'set_mce_nospec' function within the 'mce' module is designed to unmap specific pages to mitigate potential speculative execution attacks. However, due to a flaw, this function fails to unmap the entire page, leaving a portion of it vulnerable to exploitation.

Vulnerability Detail

The vulnerability arises from the 'set_mce_nospec' function's failure to fully unmap the affected page. As a result, an attacker could potentially access and manipulate the unmapped portion of the page, leading to unauthorized data disclosure or modification. This vulnerability could be exploited to bypass security measures, gain elevated privileges, or launch further attacks on the system. It is important to note that the impact and attack plausibility of this vulnerability have not been proven yet.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

As a workaround, users can manually modify the affected code in the Kernel to ensure that the 'set_mce_nospec' function unmaps the entire page. The following code snippet demonstrates the necessary modification:

// Original code
void set_mce_nospec(struct page *page)
{
    // Existing code
}

// Modified code
void set_mce_nospec(struct page *page)
{
    // New code to unmap the whole page
    unmap_page_range(page->vm_start, page->vm_end);
}

Conclusion

In conclusion, the Kernel's 'mce' module contains a vulnerability in the 'set_mce_nospec' function, which fails to unmap the entire page. This flaw could be exploited to gain unauthorized access or manipulate sensitive data. It is crucial to update the Linux Kernel to version v5.18.3 or later to mitigate this vulnerability. Additionally, a workaround is available by manually modifying the affected code. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

The Kernel is a critical component of the Linux operating system that acts as a bridge between the hardware and software layers. It provides essential functionalities and services to enable the proper functioning of the system.

The 'mce' module within the Kernel is responsible for handling machine check exceptions (MCEs). MCEs are hardware-generated interrupts that indicate potential hardware errors or inconsistencies.

The 'set_mce_nospec' function is designed to unmap specific pages in order to mitigate potential speculative execution attacks. It helps protect against unauthorized access and manipulation of sensitive data.

Speculative execution attacks are a type of security vulnerability where an attacker exploits the speculative execution capabilities of modern processors to access or manipulate sensitive data that should be protected.

If successfully exploited, this vulnerability could allow an attacker to access and manipulate the unmapped portion of a page, potentially leading to unauthorized data disclosure or modification. This could be used to bypass security measures, gain elevated privileges, or launch further attacks on the system.

Related vulnerabilities

Recent vulnerabilities recorded for Kernel.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback