CVE-2025-40167
BaseFortify
Publication date: 2025-11-12
Last updated on: 2025-11-12
Assigner: kernel.org
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| linux | linux_kernel | * |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-UNKNOWN |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
This vulnerability occurs in the Linux kernel's ext4 filesystem where an inode has an invalid combination of flags: both INLINE_DATA and EXTENTS are set. Normally, an inode should have either INLINE_DATA (data stored directly in the inode) or EXTENTS (data stored in extent-mapped blocks), but not both. This invalid combination causes the system to skip extent tree validation, leading to a BUG_ON error due to corrupted extent trees and integer underflow when calculating hole sizes. The fix involves detecting this invalid flag combination early and rejecting the corrupted inode.
How can this vulnerability impact me? :
This vulnerability can cause the Linux kernel to encounter a BUG_ON error when accessing corrupted ext4 filesystems with the invalid flag combination. This can lead to system instability or crashes when opening certain files, potentially causing data loss or denial of service on affected systems.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by checking for ext4 filesystem errors related to inodes having both INLINE_DATA and EXTENTS flags set, which is invalid. Specifically, look for kernel log messages similar to: 'EXT4-fs error (device loop0): ext4_cache_extents:545: inode #15: comm syz.0.17: corrupted extent tree: lblk 0 < prev 66'. You can use the command 'dmesg | grep EXT4-fs' to find such errors. Additionally, inspecting inode flags on the ext4 filesystem for the invalid combination may require custom scripts or kernel debugging tools, as standard tools do not directly expose this condition.
What immediate steps should I take to mitigate this vulnerability?
Immediate mitigation involves ensuring that ext4 filesystems are not mounted without a journal if they might be corrupted, as the issue occurs on corrupted ext4 filesystems mounted without a journal. Also, updating the Linux kernel to a version that includes the fix which detects and rejects inodes with both INLINE_DATA and EXTENTS flags set early in ext4_iget() is recommended to prevent the BUG_ON condition.