Linux Kernel nilfs2 Module Use-After-Free Vulnerability in Buffer Management

Vulnerability

A use-after-free vulnerability has been identified in the nilfs2 file system module of the Linux kernel. The issue arises in the function nilfs_lookup_dirty_data_buffers(), which accesses buffers linked to dirty data folios without properly locking the folios. This oversight can lead to use-after-free scenarios, especially when nilfs_clear_folio_dirty() is called asynchronously, such as when the file system becomes read-only. In such cases, the buffers may be freed by try_to_free_buffers() after losing their dirty state, creating a race condition. The vulnerability has been addressed by modifying the locking mechanism in the affected function.

Impact

Exploitation of this vulnerability can lead to use-after-free conditions, potentially allowing for arbitrary code execution or memory corruption.

Added: Jun 9, 2025, 7:46 PM
Updated: Jun 9, 2025, 7:46 PM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
2.5
exploitability
4.0
remediation
0.0
relevance
0.0
threat
3.2
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.