CVE-2026-98979

namespace: refuse an automount below a mount that is in no namespace

State
Published
Severity
Not scored
Published
Oct 23, 2026
Updated
Oct 30, 2026
Reserved
Sep 25, 2026

Read the record on cve.org

Description

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

namespace: refuse an automount below a mount that is in no namespace

It's possible to add autmounts even when the parent mount isn't in the mount namespace of the caller. The only requirement we have is that the parent mount namespace must not be NULL, i.e., unmounted.

Problem is that clone_private_mount() has MNT_NS_INTERNAL which makes that trivially true. So that passes the test and attach_recursive_mnt() accepts that as a mount point and funny enough, count_mounts() dereferences MNT_NS_INTERNAL. The problem is it is an error pointer...

So we can reach this in userspace via fanotify. A filesystem mark on the lower filesystem of an overlay reports paths on the layer clone and reading the event hands out a descriptor on it. For example with debugfs as the lower layer it goes kaboom:

openat(evfd, "tracing", O_DIRECTORY)

Oops: general protection fault KASAN: null-ptr-deref in range [0x1d0-0x1d7] RIP: 0010:count_mounts+0x35/0x200 attach_recursive_mnt finish_automount

And since that sleeping beauty happens under namespace_sem held for writing every mount operation on the system blocks from then on. Congrats.

Use is_mounted() instead which rejects unmounted and internal mounts alike. The open fails with EINVAL just as it did before clone_private_mount() used MNT_NS_INTERNAL.

Scores

The record has no CVSS score.

Weaknesses

The record names no weakness.

Affected Products

ProductVersions
LinuxLinux
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before d8c7f74adf5de78035d41aa33c8f71e12b3ca430Affected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before c88546071d30417ab9e55821c83f4dc7756cff6fAffected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before c98e74d73a3356ab00fc6bb9dec3c77da1ec1ce4Affected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before 95fb7c259b86f5521f04973040ad492f2bef6f82Affected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before 35f2013f83ef16f9f0331c4c3a8e8d161580d574Affected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before 494c57572d2d5bc2839553ed41aabe92ed0f587cAffected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before 776e20e4fdc23c23687b511ffdc80047878049d3Affected
  • df820f8de4e481222b17f9bcee7b909ae8167529 to before ba985ce08471c555af2a2fbe217c1bc2e72a6d8cAffected
LinuxLinux
  • 5.8Affected
  • before 5.8Not affected
  • 5.10.273 through 5.10.*Not affected
  • 5.15.224 through 5.15.*Not affected
  • 6.1.191 through 6.1.*Not affected
  • 6.6.160 through 6.6.*Not affected
  • 6.12.113 through 6.12.*Not affected
  • 6.18.57 through 6.18.*Not affected
  • 7.2.11 through 7.2.*Not affected
  • 7.3 and laterNot affected

References

Every record here comes from the CVE Program’s CVE List. © 1999–2026 The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation. The records are reproduced under the CVE Program terms of use.