{"api_version":"1","generated_at":"2026-12-04T13:41:33+00:00","cve":"CVE-2026-142818","urls":{"html":"https://cve.report/CVE-2026-142818","api":"https://cve.report/api/cve/CVE-2026-142818.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2026-142818","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2026-142818"},"summary":{"title":"ns: don't add init_ipc_ns and init_net without namespace support","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nns: don't add init_ipc_ns and init_net without namespace support\n\nWhen CONFIG_IPC_NS or CONFIG_NET_NS are turned off we still add the\ninitial ipc and network namespace to the namespace trees. ipc_ns_init()\ncalls ns_tree_add(&init_ipc_ns) whenever CONFIG_SYSVIPC is set and\nsetup_net() calls ns_tree_add_raw() on init_net whenever CONFIG_NET is\nset.\n\nBut without CONFIG_IPC_NS and CONFIG_NET_NS these aren't namespaces\nuserspace can do anything with. They don't have proc_ns_operations so\nthere's no /proc/<pid>/ns/{ipc,net} for them, nsfs_fh_to_dentry()\nrefuses them with -EOPNOTSUPP, and since ns->ops is NULL\n__ns_tree_add_raw() doesn't add them to the owner list of init_user_ns\neither. So they end up half registered. That's also not how we treat\nany of the other namespace types. Without CONFIG_UTS_NS, CONFIG_PID_NS,\nCONFIG_TIME_NS or CONFIG_USER_NS the initial namespace is never added\nto the tree.\n\nlistns() walks the unified tree and calls is_current_namespace() for\nevery namespace it finds via may_list_ns(). But is_current_namespace()\nonly knows about CLONE_NEWIPC and CLONE_NEWNET if CONFIG_IPC_NS and\nCONFIG_NET_NS are set. Otherwise we end up in the default case and its\nVFS_WARN_ON_ONCE(). Any unprivileged caller can trigger that with a\nplain listns() call:\n\n  WARNING: CPU: 0 PID: 526 at fs/nsfs.c:508 is_current_namespace+0x12f/0x440\n  Call Trace:\n   legitimize_ns+0x25f/0x4c0\n   do_listns+0x185/0x5c0\n   __do_sys_listns+0x13b/0x300\n\nInstead of teaching is_current_namespace() about namespaces that can't\nbe opened, only add the initial namespaces to the tree if their\nnamespace type is enabled. Move the registration of init_ipc_ns into\nipc/namespace.c which is only built with CONFIG_IPC_NS. That also fixes\nCONFIG_SYSVIPC=n, CONFIG_POSIX_MQUEUE=y, CONFIG_IPC_NS=y where\nipc/shm.c isn't built and init_ipc_ns was never added at all. For the\nnetwork namespace only call ns_tree_add_raw() if CONFIG_NET_NS is set.\nWithout CONFIG_NET_NS cleanup_net() isn't built and init_net is never\nremoved so there's nothing to balance.","state":"PUBLISHED","assigner":"Linux","published_at":"2026-12-03 04:18:17","updated_at":"2026-12-03 04:18:17"},"problem_types":[],"metrics":[],"references":[{"url":"https://git.kernel.org/stable/c/82f1c815aaef1905c5c6c386c8a0d74f6ff70a54","name":"https://git.kernel.org/stable/c/82f1c815aaef1905c5c6c386c8a0d74f6ff70a54","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/e0efb02fd551fe5e76e959a3112f55a612fa20e0","name":"https://git.kernel.org/stable/c/e0efb02fd551fe5e76e959a3112f55a612fa20e0","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/0b014c734f70d258bb1c112b2bd6598fdcbce7b0","name":"https://git.kernel.org/stable/c/0b014c734f70d258bb1c112b2bd6598fdcbce7b0","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-142818","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-142818","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 74b24a582e1ff3960f0454f57afc2bcdbc52562e 0b014c734f70d258bb1c112b2bd6598fdcbce7b0 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 74b24a582e1ff3960f0454f57afc2bcdbc52562e e0efb02fd551fe5e76e959a3112f55a612fa20e0 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 74b24a582e1ff3960f0454f57afc2bcdbc52562e 82f1c815aaef1905c5c6c386c8a0d74f6ff70a54 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 6.18","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.18 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.18.64 6.18.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.3.4 7.3.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.4-rc1 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[],"vendor_comments":[],"enrichments":{"kev":null,"epss":{"cve_year":"2026","cve_id":"142818","cve":"CVE-2026-142818","epss":"0.002930000","percentile":"0.235460000","score_date":"2026-12-03","updated_at":"2026-12-04 00:14:18"},"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["ipc/namespace.c","ipc/shm.c","net/core/net_namespace.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"0b014c734f70d258bb1c112b2bd6598fdcbce7b0","status":"affected","version":"74b24a582e1ff3960f0454f57afc2bcdbc52562e","versionType":"git"},{"lessThan":"e0efb02fd551fe5e76e959a3112f55a612fa20e0","status":"affected","version":"74b24a582e1ff3960f0454f57afc2bcdbc52562e","versionType":"git"},{"lessThan":"82f1c815aaef1905c5c6c386c8a0d74f6ff70a54","status":"affected","version":"74b24a582e1ff3960f0454f57afc2bcdbc52562e","versionType":"git"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["ipc/namespace.c","ipc/shm.c","net/core/net_namespace.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"status":"affected","version":"6.18"},{"lessThan":"6.18","status":"unaffected","version":"0","versionType":"semver"},{"lessThanOrEqual":"6.18.*","status":"unaffected","version":"6.18.64","versionType":"semver"},{"lessThanOrEqual":"7.3.*","status":"unaffected","version":"7.3.4","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"7.4-rc1","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.18.64","versionStartIncluding":"6.18","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.3.4","versionStartIncluding":"6.18","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.4-rc1","versionStartIncluding":"6.18","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nns: don't add init_ipc_ns and init_net without namespace support\n\nWhen CONFIG_IPC_NS or CONFIG_NET_NS are turned off we still add the\ninitial ipc and network namespace to the namespace trees. ipc_ns_init()\ncalls ns_tree_add(&init_ipc_ns) whenever CONFIG_SYSVIPC is set and\nsetup_net() calls ns_tree_add_raw() on init_net whenever CONFIG_NET is\nset.\n\nBut without CONFIG_IPC_NS and CONFIG_NET_NS these aren't namespaces\nuserspace can do anything with. They don't have proc_ns_operations so\nthere's no /proc/<pid>/ns/{ipc,net} for them, nsfs_fh_to_dentry()\nrefuses them with -EOPNOTSUPP, and since ns->ops is NULL\n__ns_tree_add_raw() doesn't add them to the owner list of init_user_ns\neither. So they end up half registered. That's also not how we treat\nany of the other namespace types. Without CONFIG_UTS_NS, CONFIG_PID_NS,\nCONFIG_TIME_NS or CONFIG_USER_NS the initial namespace is never added\nto the tree.\n\nlistns() walks the unified tree and calls is_current_namespace() for\nevery namespace it finds via may_list_ns(). But is_current_namespace()\nonly knows about CLONE_NEWIPC and CLONE_NEWNET if CONFIG_IPC_NS and\nCONFIG_NET_NS are set. Otherwise we end up in the default case and its\nVFS_WARN_ON_ONCE(). Any unprivileged caller can trigger that with a\nplain listns() call:\n\n  WARNING: CPU: 0 PID: 526 at fs/nsfs.c:508 is_current_namespace+0x12f/0x440\n  Call Trace:\n   legitimize_ns+0x25f/0x4c0\n   do_listns+0x185/0x5c0\n   __do_sys_listns+0x13b/0x300\n\nInstead of teaching is_current_namespace() about namespaces that can't\nbe opened, only add the initial namespaces to the tree if their\nnamespace type is enabled. Move the registration of init_ipc_ns into\nipc/namespace.c which is only built with CONFIG_IPC_NS. That also fixes\nCONFIG_SYSVIPC=n, CONFIG_POSIX_MQUEUE=y, CONFIG_IPC_NS=y where\nipc/shm.c isn't built and init_ipc_ns was never added at all. For the\nnetwork namespace only call ns_tree_add_raw() if CONFIG_NET_NS is set.\nWithout CONFIG_NET_NS cleanup_net() isn't built and init_net is never\nremoved so there's nothing to balance."}],"providerMetadata":{"dateUpdated":"2026-12-03T03:20:38.303Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/0b014c734f70d258bb1c112b2bd6598fdcbce7b0"},{"url":"https://git.kernel.org/stable/c/e0efb02fd551fe5e76e959a3112f55a612fa20e0"},{"url":"https://git.kernel.org/stable/c/82f1c815aaef1905c5c6c386c8a0d74f6ff70a54"}],"title":"ns: don't add init_ipc_ns and init_net without namespace support","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2026-142818","datePublished":"2026-12-03T03:20:38.303Z","dateReserved":"2026-12-03T03:10:28.331Z","dateUpdated":"2026-12-03T03:20:38.303Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"},"nvd":{"publishedDate":"2026-12-03 04:18:17","lastModifiedDate":"2026-12-03 04:18:17","problem_types":[],"metrics":[],"configurations":[]},"legacy_mitre":{"record":{"CveYear":"2026","CveId":"142818","Ordinal":"1","Title":"ns: don't add init_ipc_ns and init_net without namespace support","CVE":"CVE-2026-142818","Year":"2026"},"notes":[{"CveYear":"2026","CveId":"142818","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nns: don't add init_ipc_ns and init_net without namespace support\n\nWhen CONFIG_IPC_NS or CONFIG_NET_NS are turned off we still add the\ninitial ipc and network namespace to the namespace trees. ipc_ns_init()\ncalls ns_tree_add(&init_ipc_ns) whenever CONFIG_SYSVIPC is set and\nsetup_net() calls ns_tree_add_raw() on init_net whenever CONFIG_NET is\nset.\n\nBut without CONFIG_IPC_NS and CONFIG_NET_NS these aren't namespaces\nuserspace can do anything with. They don't have proc_ns_operations so\nthere's no /proc/<pid>/ns/{ipc,net} for them, nsfs_fh_to_dentry()\nrefuses them with -EOPNOTSUPP, and since ns->ops is NULL\n__ns_tree_add_raw() doesn't add them to the owner list of init_user_ns\neither. So they end up half registered. That's also not how we treat\nany of the other namespace types. Without CONFIG_UTS_NS, CONFIG_PID_NS,\nCONFIG_TIME_NS or CONFIG_USER_NS the initial namespace is never added\nto the tree.\n\nlistns() walks the unified tree and calls is_current_namespace() for\nevery namespace it finds via may_list_ns(). But is_current_namespace()\nonly knows about CLONE_NEWIPC and CLONE_NEWNET if CONFIG_IPC_NS and\nCONFIG_NET_NS are set. Otherwise we end up in the default case and its\nVFS_WARN_ON_ONCE(). Any unprivileged caller can trigger that with a\nplain listns() call:\n\n  WARNING: CPU: 0 PID: 526 at fs/nsfs.c:508 is_current_namespace+0x12f/0x440\n  Call Trace:\n   legitimize_ns+0x25f/0x4c0\n   do_listns+0x185/0x5c0\n   __do_sys_listns+0x13b/0x300\n\nInstead of teaching is_current_namespace() about namespaces that can't\nbe opened, only add the initial namespaces to the tree if their\nnamespace type is enabled. Move the registration of init_ipc_ns into\nipc/namespace.c which is only built with CONFIG_IPC_NS. That also fixes\nCONFIG_SYSVIPC=n, CONFIG_POSIX_MQUEUE=y, CONFIG_IPC_NS=y where\nipc/shm.c isn't built and init_ipc_ns was never added at all. For the\nnetwork namespace only call ns_tree_add_raw() if CONFIG_NET_NS is set.\nWithout CONFIG_NET_NS cleanup_net() isn't built and init_net is never\nremoved so there's nothing to balance.","Type":"Description","Title":"ns: don't add init_ipc_ns and init_net without namespace support"}]}}}