HIGH Introduced in 3.12
namespace LockedMount Bypass
CVE-2026-98978
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:N
KernelScan AI6.6MEDIUM
01Description
In the Linux kernel, the following vulnerability has been resolved: namespace: never expire a locked mount Locked mounts are special. They protect the underlying files and directories from being revealed. do_umount() refuses to unmount locked mounts but shrink_submounts() doesn't. A shrinkable mount can become locked once the owner of a user namespace puts it beneath a locked mount with MOVE_MOUNT_BENEATH. The locked property now moves to the mount at the bottom making it possible to unmount the top mount. So umount() of an unlocked ancestor now expires the bottom mount first and the covered directory is revealed: move_mount(c -> x/hidden, MOVE_MOUNT_BENEATH) = 0 the cover after the lock moved: umount2(x/hidden) = 0 the holder of the lock: umount2(x/hidden) = EINVAL the root of the copy, busy: umount2(x) = EBUSY reads x/hidden/secret: "covered-by-root" So leave a locked mount alone as it dies together with its parent. A plain umount() of an unlocked mount with a locked one below it is EBUSY from now on. It's the same for any other locked child. A lazy umount still takes the whole tree. mark_mounts_for_expiry() never sees a locked mount. lock_mnt_tree() leaves a mount on an expiry list alone and nothing else puts a locked one on such a list. Add an assert for this.
02KernelScan AI Analysis
Risk summary
A local attacker with access to an unprivileged user namespace can bypass mount lock protections by moving a shrinkable mount beneath a locked mount, then triggering expiry of the now-locked child mount. This reveals files and directories that were intentionally hidden by the lock, violating the expectation that locked mounts cannot be unmounted individually. The vulnerability affects any system where unprivileged user namespaces are enabled.
Vulnerability analysis
The kernel's automatic mount cleanup did not honor the 'locked' flag that protects mounts from being removed, even though the manual unmount command correctly respects it. An attacker with a user namespace can exploit this by moving an expirable mount beneath a locked mount, which transfers the lock to the lower mount. When the upper mount is then unmounted, the cleanup code incorrectly removes the now-locked lower mount first, exposing the files that were meant to stay hidden. The fix makes the cleanup code skip locked mounts, and adds a safety check to catch any future regressions. The attack only needs an unprivileged user namespace and local code execution, so it works from containers and regular user sessions on most systems.
Lifecycle
03Fix Versions
| Branch | Introduced | Fixed in | Patch commit |
|---|---|---|---|
| 6.18 | 3.12 | 6.18.57 | 6b8dc3713a76 |
| 7.2 | 3.12 | 7.2.11 | d23265a12e49 |
| mainline | 3.12 | 7.3 | f78ddcc87224 |
04CIP Kernels
State of the newest release of each Civil Infrastructure Platform SLTS tree, from CIP's own fix records.
| CIP tree | State |
|---|---|
| cip/6.12 | Affected — no CIP fix yet (latest 6.12.114-cip34) |
| cip/6.1 | Affected — no CIP fix yet (latest 6.1.190-cip62) |
| cip/6.1-rt | Affected — no CIP fix yet (latest 6.1.189-cip61-rt32) |
| cip/5.10 | Affected — no CIP fix yet (latest 5.10.272-cip79) |
| cip/5.10-rt | Affected — no CIP fix yet (latest 5.10.272-cip79-rt35) |
| cip/4.19 | Affected — no CIP fix yet (latest 4.19.325-cip136) |
| cip/4.19-rt | Affected — no CIP fix yet (latest 4.19.325-cip136-rt50) |
| cip/4.4 | Affected — no CIP fix yet (latest 4.4.302-cip115) |
| cip/4.4-rt | Affected — no CIP fix yet (latest 4.4.302-cip115-rt63) |