Skip to content
Medium 4.7

landlock: Fix superblock use-after-free in release_inode()

CVE-2026-99514 First seen on SecPulse

Affected packages

PackageAffected → Fixed
LinuxLinux —
LinuxKernel
≥ 5.13.0, < 5.15.226→ 5.15.226
≥ 5.16.0, < 6.1.193→ 6.1.193
≥ 6.2.0, < 6.6.163→ 6.6.163
≥ 6.7.0, < 6.12.117→ 6.12.117
≥ 6.13.0, < 6.18.61→ 6.18.61
≥ 6.19.0, < 7.3.2→ 7.3.2

Fix status by distribution

Records published by each distribution for this CVE. Fixed versions differ by release; check each link.

Original description The description as published by the source.

In the Linux kernel, the following vulnerability has been resolved:

landlock: Fix superblock use-after-free in release_inode()

Without this fix, release_inode() (task 1) can race with a umount
operation in hook_sb_delete() (task 2). The order of operations in
which the race occurs is:

  • task 2: hook_sb_delete() arrives at the end of the function, waiting
    for landlock_superblock(sb)->inode_refs to become zero.
  • task 1: release_inode(): does atomic_long_dec_and_test(), decrementing
    inode_refs to zero.
  • task 2: gets woken up through some other means, sees that inode_refs
    is zero and returns. The caller is the unmount operation and proceeds
    to release the superblock.
  • task 1: Runs wake_up_var(&landlock_superblock(sb)->inode_refs),
    dereferencing the sb_security on the freed-up superblock.

Notably, wake_up_var() does not dereference the pointer passed to it,
and only uses it to determine an overapproximated set of tasks to wake
up. So while it's potentially possible for an attacker to provide a
different value for that pointer, this only results in the wrong set of
tasks getting woken up, and in this scenario, no further tasks are
actually waiting.

Nevertheless, KASAN detects it as a slab-use-after-free read on
sb->s_security:

BUG: KASAN: slab-use-after-free in release_inode+0x196/0x290
Read of size 8 at addr ffff888103b6c0a8 by task repro/217
release_inode+0x196/0x290
landlock_put_object+0x71/0x90
landlock_free_rules+0x38/0xc0
landlock_put_ru…

Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details