AZL-116839: CVE-2026-139051 affecting package kernel 6.6.161.1-1
In the Linux kernel, the following vulnerability has been resolved:
fs: make sure to call fsnotifyinoderemove() only once when inode is dead
Daehyeon reported a race wherein fsnotifyremoveinode() can be called when inode still has a live alias. This can lead to several undesired outcomes such as crashes in fsnotify code or avoidance of inode mark notifications.
Check that inode is really "dead", meaning no nlink and no more aliases before calling fsnotifyinoderemove() for final cleanup of inode marks. Also do not allow openbyhandle() to add new aliases to a "dead" inode.
Ideally, we'd call fsnotifyinoderemove() once last inode reference is dropped to make things simpler. Alas fsnotify inode marks currently hold inode references and thus this doesn't work. Once we teach fsnotify to avoid holding inode references, these games with dead inodes can go as well.
Affected Software
Event History
Frequently Asked Questions
What conditions are required for this issue to occur?
The issue requires a race in filesystem notification handling where fsnotify_removeinode() is invoked while the inode still has a live alias. Affected behavior involves inode removal and alias handling, including the possibility of open_by_handle() adding aliases to an inode considered dead.
What could be the impact if the race is triggered?
The race can cause crashes in fsnotify code or allow inode mark notifications to be avoided. The fix ensures final inode-mark cleanup occurs only after the inode has no links and no remaining aliases.
How does the resolved kernel behavior prevent the issue?
The resolved behavior checks that an inode is truly dead, with no nlink and no aliases, before calling fsnotify_inoderemove(). It also prevents open_by_handle() from adding new aliases to a dead inode.