CVE-2026-99051: fsverity: RCU-delay the freeing of struct fsverity_info
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
fsverity: RCU-delay the freeing of struct fsverity_info
__fsverity_get_info() calls rhashtable_lookup_fast(), which just uses rcu_read_lock() and doesn't directly synchronize with fsverity_remove_info().
For the same inode this isn't a problem: its fsverity_info is removed only at inode eviction time or upon failure to enable verity, when the inode no longer needs its fsverity_info and it will no longer be accessed via that inode.
However, this is broken and can cause a use-after-free for concurrent __fsverity_get_info() for *different* inodes. Those rely on following fsverity_info::rhash_head in the rhashtable under rcu_read_lock() only. They also use fsverity_info::inode to do the key comparison.
Fix this by RCU-delaying the freeing of 'struct fsverity_info' after it's been removed from the rhashtable.
The Linux kernel CVE team has assigned CVE-2026-99051 to this issue.
Affected and fixed versions
===========================
Issue introduced in 7.0 with commit f77f281b61183a5c0b87e6a4d101c70bd32c1c79 and fixed in 7.2.11 with commit fa84f091a8e7fc46fd29834496fab9739dd4c8dc Issue introduced in 7.0 with commit f77f281b61183a5c0b87e6a4d101c70bd32c1c79 and fixed in 7.3 with commit e58c3805ed325fe2d4ae2dd467c0486cc860b733
Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.
Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at
https://cve.org/CVERecord/?id=CVE-2026-99051
will be updated if fixes are backported, please check that for the most up to date information about this issue.
Affected files
==============
The file(s) affected by this issue are:
fs/verity/fsverity_private.h
fs/verity/open.c
Mitigation
==========
The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:
https://git.kernel.org/stable/c/fa84f091a8e7fc46fd29834496fab9739dd4c8dc https://git.kernel.org/stable/c/e58c3805ed325fe2d4ae2dd467c0486cc860b733