Skip to main content

Linux Kernel OCFS2 CVE-2026-31597

| EUVDEUVD-2026-25490 HIGH
Use After Free (CWE-416)
2026-04-24 Linux GHSA-8pwc-q4rq-xxf3
7.8
CVSS 3.1 · Vendor: Linux
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Gain local shell access
  2. Delivery
    Mount OCFS2 or access existing mount
  3. Exploit
    Craft mmap/munmap race condition program
  4. Install
    Trigger filemap_fault with I/O delays
  5. C2
    Win race to free vma during mmap_lock release
  6. Execute
    Spray kernel heap to control freed memory
  7. Impact
    Dereference dangling pointer in trace_ocfs2_fault
  8. Step 8
    Execute arbitrary kernel code as root

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Memory lifecycle management
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Privilege Escalation

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires Linux kernel with OCFS2 filesystem compiled and loaded (CONFIG_OCFS2_FS=y or =m). System must have OCFS2 volumes actively mounted and accessible to the attacker's user context. Attacker needs local authenticated shell access with privileges to execute mmap/munmap system calls (standard user-level access, PR:L). Successful exploitation requires winning a narrow race condition between filemap_fault dropping mmap_lock and concurrent munmap freeing the vm_area_struct, typically requiring repeated attempts or controlled I/O latency conditions. Not exploitable remotely (AV:L). Most Linux distributions do not enable or use OCFS2 by default, limiting real-world attack surface primarily to Oracle RAC cluster environments and specialized cluster filesystem deployments. Systems without OCFS2 mounted or loaded are not vulnerable despite running affected kernel versions.

Impact

While the CVSS base score of 7.8 indicates high severity, real-world risk appears moderate based on multiple signals. The CVSS vector (AV:L/AC:L/PR:L/UI:N) shows local access with low privileges is required, significantly limiting attack surface compared to network-accessible vulnerabilities. The extremely low EPSS score (0.02%, 5th percentile) suggests security researchers and threat actors have not prioritized this vulnerability for exploitation, likely due to several factors: exploitation requires OCFS2 filesystem usage (relatively uncommon outside Oracle RAC environments), precise timing to win the race condition between filemap_fault and munmap, and local authenticated access. No CISA KEV listing indicates no confirmed active exploitation in the wild. No public exploit code has been identified. The vulnerability requires specific conditions: the system must use OCFS2, an attacker needs local shell access, and exploitation demands triggering the narrow race window between mmap_lock release and vma deallocation. However, successful exploitation could yield full kernel memory corruption leading to privilege escalation to root, making this a priority for environments running OCFS2 in multi-tenant or user-accessible systems. The availability of vendor patches across multiple stable kernel branches reduces residual risk significantly for organizations with active patch management.

Exploit ScenarioDerived

A local attacker with standard user privileges on a Linux system using OCFS2 for shared storage gains initial access through compromised credentials or application vulnerability. The attacker crafts a program that repeatedly performs mmap operations on OCFS2 files while simultaneously triggering munmap in competing threads, creating a race condition. When timing succeeds, filemap_fault releases mmap_lock during I/O, allowing munmap to free the vm_area_struct while ocfs2_fault still holds the pointer. The attacker leverages heap spraying techniques to control the freed memory region, placing malicious kernel structures at the freed vma location. When trace_ocfs2_fault dereferences the dangling pointer, kernel execution flow is redirected to attacker-controlled code running at ring 0, achieving full privilege escalation to root. No public exploit code exists, but the race window and memory corruption primitive are well-understood exploitation patterns.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.0% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Apr 27, 2026

Use-after-free in Linux kernel OCFS2 filesystem enables local attackers with low privileges to achieve arbitrary code execution, privilege escalation, or denial of service. The vulnerability occurs when filemap_fault() drops mmap_lock before returning VM_FAULT_RETRY, allowing concurrent munmap() to free the vm_area_struct while ocfs2_fault() still holds a dangling pointer. Vendor patches available for kernel versions 6.12.83, 6.18.24, 6.19.14, and 7.0.1. EPSS exploitation probability is very low (0.02%, 5th percentile) with no public exploit identified at time of analysis.

RemediationAI

Upgrade to patched Linux kernel versions: 6.12.83, 6.18.24, 6.19.14, or 7.0.1 depending on your current stable branch. Upstream fixes are available at https://git.kernel.org/stable/c/4cf2768a0291a0cdd0dae801ea0eafa3878a349d and related commit references. Organizations unable to immediately patch should implement compensating controls with the following trade-offs: disable OCFS2 filesystem mounting via kernel module blacklisting (add 'install ocfs2 /bin/true' to /etc/modprobe.d/) which eliminates attack surface but breaks OCFS2-dependent cluster applications; restrict local shell access to trusted administrators only, reducing attacker capability to trigger the race condition but not eliminating risk from compromised accounts; implement kernel page table isolation (KPTI) and other kernel hardening features (CONFIG_SLAB_FREELIST_HARDENED, CONFIG_INIT_ON_ALLOC_DEFAULT_ON) to increase exploitation difficulty, though these add 5-30% performance overhead and do not prevent the underlying use-after-free. For Oracle RAC environments requiring OCFS2, schedule emergency patching windows as no effective workaround exists that maintains cluster filesystem functionality.

Affected VersionsENISA

Linux 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 <4cf2768a0291a0cdd0dae801ea0eafa3878a349d
Linux patch: 6.19.14
Linux patch: 6.18.24
Linux 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 <d45ff441b416d4aa1af72b1db23d959601c04da2
Linux 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 <925bf22c1b823e231b1baea761fe8a1512e442f2
Linux 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 <76a602fdbb78dd05b2da06f74a988cebc97e82d0
Linux patch: 7.0.1
Linux patch: 6.12.83

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

This vulnerability affects the OCFS2 (Oracle Cluster File System 2) implementation in the Linux kernel's memory management subsystem. The flaw lies in the interaction between page fault handling (filemap_fault) and virtual memory area lifecycle management. When filemap_fault() encounters a VM_FAULT_RETRY condition - typically during I/O operations or folio locking - it may release the mmap_lock semaphore as documented in mm/filemap.c. During this window, another thread executing munmap() can proceed through remove_vma() and schedule the vm_area_struct for RCU-deferred destruction. The ocfs2_fault() function retains a pointer to this freed memory and subsequently dereferences it during trace_ocfs2_fault() invocation, triggering a use-after-free condition. The fix involves capturing ip_blkno as a plain integer value before the potentially lock-dropping filemap_fault() call, ensuring the value remains valid regardless of subsequent vma or inode state changes. This represents a classic time-of-check-time-of-use (TOCTOU) race condition in kernel memory management code.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (Linux) PRIMARY 7.8 HIGH
AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
SUSE HIGH

Primary rating from Vendor (Linux).

CVSS VectorVendor: Linux

Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

4
Patch released
Apr 29, 2026 - 14:15 nvd
Patch available
CVSS changed
Apr 27, 2026 - 15:22 NVD
7.8 (HIGH)
Patch available
Apr 24, 2026 - 16:16 EUVD
CVE Published
Apr 24, 2026 - 14:42 nvd
HIGH 7.8

DescriptionCVE.org

In the Linux kernel, the following vulnerability has been resolved:

ocfs2: fix use-after-free in ocfs2_fault() when VM_FAULT_RETRY

filemap_fault() may drop the mmap_lock before returning VM_FAULT_RETRY, as documented in mm/filemap.c:

"If our return value has VM_FAULT_RETRY set, it's because the mmap_lock may be dropped before doing I/O or by lock_folio_maybe_drop_mmap()."

When this happens, a concurrent munmap() can call remove_vma() and free the vm_area_struct via RCU. The saved 'vma' pointer in ocfs2_fault() then becomes a dangling pointer, and the subsequent trace_ocfs2_fault() call dereferences it -- a use-after-free.

Fix this by saving ip_blkno as a plain integer before calling filemap_fault(), and removing vma from the trace event. Since ip_blkno is copied by value before the lock can be dropped, it remains valid regardless of what happens to the vma or inode afterward.

Executive ViewAI

Why It Matters

CVE-2026-31597 is a use-after-free vulnerability in the Linux kernel OCFS2 filesystem that allows local attackers with low privileges to execute arbitrary code or escalate privileges. Organizations running affected kernel versions face elevated risk of unauthorized access and system compromise through local attack vectors. Immediate patching of kernel versions 6.12, 6.18, 6.19, and 7.0 is required to eliminate this exposure.

Business Impact: High
Compensating Controls

Apply vendor patch. If immediate patching is not feasible, implement kernel module blacklisting to disable OCFS2 filesystem on systems that do not require this functionality, and restrict local user account access through strict privilege management and monitoring of system call activity related to memory mapping operations.

Threat Intelligence Overview

EPSS Score
0.0%
Top 95% exploitable
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.0%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact
High

Priority Score

39
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +39
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Use-after-free vulnerabilities occur when a program continues to access memory through a pointer after that memory has been deallocated.

Memory corruption occurs when a program writes data beyond the boundaries of allocated memory regions or accesses memory in unintended ways, violating the integrity of the process's address space.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Vendor StatusVendor

SUSE

Severity: High
Product Status
SUSE Linux Enterprise Desktop 15 SP7 Fixed
SUSE Linux Enterprise Desktop 15 SP7 Fixed
SUSE Linux Enterprise High Availability Extension 15 SP7 Fixed
SUSE Linux Enterprise High Availability Extension 15 SP7 Fixed
SUSE Linux Enterprise High Performance Computing 15 SP7 Fixed

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy