Skip to main content

lwext4 CVE-2025-71473

| EUVDEUVD-2025-211372 MEDIUM
Out-of-bounds Write (CWE-787)
2026-11-20 VulnCheck GHSA-q7cc-h884-47h4
6.9
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

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

  1. Access
    Craft ext4 image with oversized s_inodes_per_group
  2. Exploit
    Victim application mounts the image
  3. Execution
    memset overflows heap inode bitmap
  4. Impact
    Memory corruption crashes mounting process

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, write limits
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 the target application to mount an attacker-controlled ext4 image using lwext4 (through 1.0.0) whose superblock field s_inodes_per_group is set larger than the inode bitmap block (block_size) can represent; the overflow is triggered in ext4_fs_init_inode_bitmap() during mount-time bitmap initialization. Exploitation is LIMITED by the need for passive user/application interaction (UI:P) to mount the malicious image and by the local attack vector - there is no remote network trigger. No authentication is needed (PR:N), and default behavior is affected because the unchecked memset runs on the normal inode-bitmap init path; the practical gate is delivering the crafted image to a process that will mount it.

Impact

This is a medium-severity, availability-centric issue rather than a top-tier emergency. The supplied CVSS 4.0 vector (6.9) is AV:L/AC:L/AT:N/PR:N/UI:P, meaning local attack vector with low complexity, no privileges (unauthenticated), but passive user interaction is required - specifically, a victim application must mount an attacker-supplied ext4 image. Impact is skewed toward availability (VA:H, a crash of the mounting application) with only limited integrity impact (VI:L) and no confidentiality impact (VC:N), consistent with CWE-787 out-of-bounds write via an unchecked memset. No KEV listing is present (no confirmed active exploitation), no EPSS score was provided in the input (exploitation-probability signal is MISSING and cannot be weighed), and no reference is tagged as working exploit code, so this is 'no public exploit identified at time of analysis.' The vuln.today priority label is 'this_month,' aligning with the medium score and the local, interaction-gated vector - a real but non-urgent fix-on-normal-cadence item. The key limiting factor is that exploitation is not remote-automatable: an attacker must get a crafted filesystem image in front of a process that uses lwext4 to mount it. Note the local vector (AV:L) reflects that the attack surface is image parsing, not a network service, despite PR:N.

Exploit ScenarioDerived

An attacker crafts an ext4 filesystem image whose superblock sets s_inodes_per_group far larger than the inode bitmap block can hold, then gets a victim to mount it with an application built on lwext4 (for example a firmware tool, forensic utility, or IoT/bootloader component that auto-mounts attached storage or image files). When ext4_fs_init_inode_bitmap() runs, memset writes past the heap-allocated bitmap buffer, corrupting adjacent memory and crashing the process. No confirmed working exploit code was identified; a vendor advisory (VulnCheck) and upstream issue/patch describe the flaw.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.1% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Nov 20, 2026

Heap-based memory corruption in lwext4 through 1.0.0 is triggered when the library mounts a crafted ext4 image whose superblock declares an s_inodes_per_group value larger than the inode bitmap block can represent, causing the memset in ext4_fs_init_inode_bitmap() (src/ext4_fs.c) to write past a heap buffer sized to block_size. Exploitation is local and requires passive interaction - a user or application must mount the attacker-supplied image (AV:L, UI:P, PR:N) - and the assessed impact is availability-dominant, crashing the mounting application through heap corruption, with only limited integrity impact and no confidentiality impact; there is no remote network trigger. No public exploit code was identified at time of analysis and the issue is not in CISA KEV, but upstream fix code has been merged (PR #111).

RemediationAI

Apply the upstream fix from gkostka/lwext4, delivered through pull request https://github.com/gkostka/lwext4/pull/111 and commit b9c842f168e6044bd03fe34e1237eda33c299908 (mirrored in the Aladdin-R-D fork as commit 2f5714d42f729fbdf3e65fd24d57149619fa1f33); no tagged release version containing the fix is confirmed in the available data, so downstream projects should cherry-pick the commit or pin to a source revision that includes it. The patch rejects oversized geometries in ext4_fs_init_inode_bitmap() with the check if(((inodes_per_group + 7) / 8) > block_size) return EFAULT; and adds an equivalent bound check in ext4_fs_init_block_bitmap(). Where the library cannot be updated immediately, add pre-mount validation of image superblock fields and refuse any image whose s_inodes_per_group exceeds 8 x block_size - the trade-off is that images with unusual but legitimate geometry may be rejected and an extra parsing layer is required - and mount untrusted images inside an isolated, unprivileged process so that a crashed or corrupted mount cannot affect the host application; sandboxing limits the blast radius of the crash but does not correct the underlying out-of-bounds write.

Affected VersionsENISA

lwext4 0 ≤1.0.0

Affected Packages

euvd lwext4 no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

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

Technical ContextAI · show details

lwext4 is a small, dependency-free C library that implements ext2/ext3/ext4 filesystem support for embedded targets, bootloaders and firmware, parsing on-disk structures such as the superblock and block group descriptors directly from an image or block device. The flaw is an out-of-bounds write (CWE-787) in the mount-time inode bitmap initialisation path: the code derives the bitmap size from the attacker-controlled superblock field s_inodes_per_group, computed as (inodes_per_group + 7) / 8 bytes, and memsets that many bytes into b.data, a heap buffer allocated with the filesystem block size. Because s_inodes_per_group from the image was never validated against block_size, an oversized value makes the memset run past the allocation and corrupt adjacent heap memory before the mount completes. The same PR adds a sibling bound check in ext4_fs_init_block_bitmap(), and the code at v1.0.0 src/ext4_fs.c lines 401-405 is the reference for the vulnerable path; any consumer that mounts untrusted or downloaded images inherits the issue.

Know when Lwext4 gets its next vulnerability

  • 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 (VulnCheck) PRIMARY 6.9 MEDIUM
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:H/SC:N/SI:N/SA:N
vuln.today AI 6.1 MEDIUM

Local image-parsing surface requiring the victim to mount a crafted image (AV:L, UI:R), no auth (PR:N); impact is primarily a crash (A:H) with limited memory integrity (I:L) and no confidentiality.

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:H
4.0 AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
Low
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

lwext4 through 1.0.0 contains a heap buffer overflow in ext4_fs_init_inode_bitmap() in src/ext4_fs.c because it does not validate s_inodes_per_group against the inode bitmap size. Attackers can supply a crafted ext4 image with an oversized s_inodes_per_group so memset writes past the heap buffer, corrupting memory and crashing the mounting application.

Threat Intelligence Overview

EPSS Score
0.1%
Top 97% exploitable
Prevalence
Low
niche embedded ext2/3/4 filesystem library used in firmware/IoT, not enterprise-ubiquitous
Social Media
1
Sightings
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 MEDIUM
CISA KEV No
Public POC No
EPSS 0.1%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.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
Defer
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

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

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

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.

Related Vulnerabilities in lwext4 Heap Buffer Overflow Vulnerabilities

View all 2

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