Linux Kernel OverlayFS Inode Handling Vulnerability in inotify Integration

Vulnerability

A vulnerability in the Linux kernel's OverlayFS implementation can be triggered by userspace interactions with inotify. When an OverlayFS inode's dentry aliases are discarded, the inotify_show_fdinfo() function can encounter a WARN_ON() assertion failure. This issue arises because the function fails to encode the file handle for the OverlayFS inode, which is critical for proper event reporting. The problem stems from the ovl_encode_fh() function's reliance on finding an alias for the inode, a step that can be deferred to avoid failures in common scenarios, such as with FAN_DELETE_SELF events.

Impact

The vulnerability disrupts the proper encoding of OverlayFS file handles, leading to incomplete reporting of fanotify events, particularly those related to self-deletion.

Reproduction

The vulnerability can be reproduced by creating an OverlayFS watched inode and then discarding its dentry aliases. Following this, calling the inotify_show_fdinfo() function will trigger the WARN_ON() assertion, demonstrating the failure to encode the OverlayFS file handle.

Remediation

No specific remediation is provided, but the issue has been addressed in the Linux kernel.

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
5.7
remediation
0.0
relevance
0.0
threat
4.8
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.