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

unshare: don't drop active namespace references that were never taken

Active references on the namespaces of an nsproxy are taken when the
nsproxy is installed into a task in switch_task_namespaces() and
copy_namespaces() and dropped again by put_nsproxy() through
deactivate_nsproxy().

But ksys_unshare() calls put_nsproxy() on an nsproxy that was never
installed when set_cred_ucounts() fails. The new namespaces of that
nsproxy go from zero to minus one and the namespaces shared with the
caller lose a reference that belongs to the nsproxy the caller keeps
using:

WARNING: kernel/nscommon.c:171 at __ns_ref_active_put+0x1cd/0x230
nsproxy_ns_active_put
deactivate_nsproxy
ksys_unshare

Afterwards the namespaces the caller lives in aren't listed by listns()
anymore. set_cred_ucounts() only fails when alloc_ucounts() can't
allocate and it only allocates when the real uid of the caller differs
from its effective uid.

Commit cefd55bd2159 ("nsproxy: fix free_nsproxy() and simplify
create_new_namespaces()") separated the two cases on purpose.
nsproxy_free() frees an nsproxy that was prepared but never installed
and that's what a failed setns() uses in put_nsset(). Export it and use
it for a failed unshare() as well.
Published: 2026-10-23
Score: 4.7 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Namespace reference mismanagement
Action: Patch promptly
AI Analysis

Impact

The vulnerability in the Linux kernel’s nsproxy handling causes active namespace reference counts to become negative when an unshare operation fails due to a set_cred_ucounts error. This negative count undermines the integrity of namespace reference tracking, leading to references being incorrectly dropped and namespaces that a caller uses no longer appearing in listns. The flaw could produce instability by leaving namespaces in an inconsistent state, but the description does not specify a direct crash or memory corruption.

Affected Systems

The vulnerability affects Linux kernel installations that lack commit cefd55bd2159. No specific kernel versions are listed, so all current kernels missing this commit may be vulnerable. System administrators should verify that the running kernel contains the fix introduced by the commit.

Risk and Exploitability

The likely attack vector is local; based on the description, a local user capable of invoking the unshare system call could trigger the vulnerability. The EPSS score of less than 1% indicates a very low probability of exploitation, and it is not listed in the CISA KEV catalog, implying no known widespread current use. The CVSS score of 4.7 denotes medium severity; while the exact impact may not be a crash, the inconsistent namespace state could disrupt affected processes. The lack of publicly available exploits suggests that immediate exploitation is unlikely, but the potential impact warrants timely patching.

Generated by OpenCVE AI on October 29, 2026 at 22:47 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Update the system to a Linux kernel that includes commit cefd55bd2159, which correctly handles nsproxy cleanup during unshare failures.
  • If a kernel upgrade cannot be performed immediately, restrict or disable unshare usage in time‑critical or exposed services until a fix is available.
  • After applying the patch, monitor kernel logs for __ns_ref_active_put warnings and verify that listns continues to list all active namespaces as expected.

Generated by OpenCVE AI on October 29, 2026 at 22:47 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Thu, 29 Oct 2026 21:45:00 +0000

Type Values Removed Values Added
Weaknesses CWE-416

Thu, 29 Oct 2026 12:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-911
References
Metrics threat_severity

None

cvssV3_1

{'score': 4.7, 'vector': 'CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:H'}

threat_severity

Moderate


Fri, 23 Oct 2026 21:30:00 +0000

Type Values Removed Values Added
First Time appeared Linux linux
Vendors & Products Linux linux

Fri, 23 Oct 2026 17:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-416

Fri, 23 Oct 2026 12:45:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: unshare: don't drop active namespace references that were never taken Active references on the namespaces of an nsproxy are taken when the nsproxy is installed into a task in switch_task_namespaces() and copy_namespaces() and dropped again by put_nsproxy() through deactivate_nsproxy(). But ksys_unshare() calls put_nsproxy() on an nsproxy that was never installed when set_cred_ucounts() fails. The new namespaces of that nsproxy go from zero to minus one and the namespaces shared with the caller lose a reference that belongs to the nsproxy the caller keeps using: WARNING: kernel/nscommon.c:171 at __ns_ref_active_put+0x1cd/0x230 nsproxy_ns_active_put deactivate_nsproxy ksys_unshare Afterwards the namespaces the caller lives in aren't listed by listns() anymore. set_cred_ucounts() only fails when alloc_ucounts() can't allocate and it only allocates when the real uid of the caller differs from its effective uid. Commit cefd55bd2159 ("nsproxy: fix free_nsproxy() and simplify create_new_namespaces()") separated the two cases on purpose. nsproxy_free() frees an nsproxy that was prepared but never installed and that's what a failed setns() uses in put_nsset(). Export it and use it for a failed unshare() as well.
Title unshare: don't drop active namespace references that were never taken
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References

Subscriptions

Linux Linux Linux Kernel
cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published:

Updated: 2026-10-23T12:20:00.918Z

Reserved: 2026-09-25T10:25:14.384Z

Link: CVE-2026-98983

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-23T13:17:20.160

Modified: 2026-10-23T13:17:20.160

Link: CVE-2026-98983

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-10-23T00:00:00Z

Links: CVE-2026-98983 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-29T23:00:06Z

Weaknesses
  • CWE-911

    Improper Update of Reference Count