CVE-2026-46040 json
inotify: fix watch count leak when fsnotify_add_inode_mark_locked() fails
published 2026-05-27 5 mo ago modified 2026-11-06 2 d ago also EUVD-2026-32421
- cvss
- 5.5
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.1%
- EPSS 0.1% chance of exploitation in 30 days, percentile 2%
- public exploits
- 0
- none known
Summary
In the Linux kernel, the following vulnerability has been resolved:
inotify: fix watch count leak when fsnotify_add_inode_mark_locked() fails
When fsnotify_add_inode_mark_locked() fails in inotify_new_watch(), the error path calls inotify_remove_from_idr() but does not call dec_inotify_watches() to undo the preceding inc_inotify_watches(). This leaks a watch count, and repeated failures can exhaust the max_user_watches limit with -ENOSPC even when no watches are active.
Prior to commit 1cce1eea0aff ("inotify: Convert to using per-namespace limits"), the watch count was incremented after fsnotify_add_mark_locked() succeeded, so this path was not affected. The conversion moved inc_inotify_watches() before the mark insertion without adding the corresponding rollback.
Add the missing dec_inotify_watches() call in the error path.
Patch / fix
- Linux Linux 5.10.258, 5.15.209, 6.1.175, 6.6.140, 6.12.86, 6.18.27, 7.0.4, 7.1
- linux Debian 12 6.1.176-1
- linux Debian 13 6.12.86-1
- linux Debian 14 7.0.4-1
debian advisories DEBIAN-CVE-2026-46040
- linux Ubuntu 22.04 LTS 5.15.0-186.196
- linux Ubuntu 24.04 LTS 6.8.0-136.136
- linux Ubuntu 26.04 LTS 7.0.0-27.27
- linux-aws Ubuntu 22.04 LTS 5.15.0-1112.119
- linux-aws Ubuntu 24.04 LTS 6.8.0-1061.64
- linux-aws Ubuntu 26.04 LTS 7.0.0-1008.8
- linux-gcp Ubuntu 22.04 LTS 5.15.0-1112.122
- linux-gcp Ubuntu 24.04 LTS 6.8.0-1064.72
ubuntu advisories UBUNTU-CVE-2026-46040
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- kernel-source Linux Micro 6.1, Linux Micro 6.0 6.4.0-51.1
- kernel-default Linux Micro 6.1, Linux Micro 6.0 6.4.0-51.1
- kernel-kvmsmall Linux Micro 6.1, Linux Micro 6.0 6.4.0-51.1
- kernel-rt Linux Micro 6.1, Linux Micro 6.0 6.4.0-51.1
- kernel-source-rt Linux Micro 6.1, Linux Micro 6.0 6.4.0-51.1
- kernel-default SLES 16.0, SLE High Availability Extension 16.0, Linux Micro 6.2 +1 more 6.12.0-160000.37.1
- kernel-rt Linux Micro 6.2 6.12.0-160000.37.1
- kernel-64kb SLES 16.0, Linux Micro 6.2, SLES for SAP applications 16.0 6.12.0-160000.37.1
suse advisories SUSE-SU-2026:23244-1SUSE-SU-2026:23241-1SUSE-SU-2026:23194-1SUSE-SU-2026:23193-1SUSE-SU-2026:3594-1SUSE-SU-2026:23237-1
- kernel-rt openSUSE Leap 16.0 6.12.0-160000.37.1
- dtb-aarch64 openSUSE Leap 16.0 6.12.0-160000.37.1
- kernel-64kb openSUSE Leap 16.0 6.12.0-160000.37.1
- kernel-syms openSUSE Leap 16.0 6.12.0-160000.37.1
- kernel-azure openSUSE Leap 16.0 6.12.0-160000.37.1
- kernel-obs-qa openSUSE Leap 16.0 6.12.0-160000.37.1
- kernel-source openSUSE Leap 16.0 6.12.0-160000.37.1
- kernel-default openSUSE Leap 16.0 6.12.0-160000.37.1
opensuse advisories openSUSE-SU-2026:21555-1openSUSE-SU-2026:10954-1
- git.kernel.org/stable/c/3ab58cf42c46bf2366d2f55ae5c59299d5e178b7 commit
- git.kernel.org/stable/c/10edf7e0ffdc7faa18e2244b17722c1b882b8273 commit
- git.kernel.org/stable/c/3ad9ccea1b25435f6179b57aa891960beb7ce8f9 commit
- git.kernel.org/stable/c/8bcc1cd237ab5ccfdd102869fa031c541943cf40 commit
- git.kernel.org/stable/c/73ddc8518a32baff6bc17afda4ee1ebae5b4ed12 commit
- git.kernel.org/stable/c/fdaa42ca370d056428e5e171247c8fdce8dff36a commit
- git.kernel.org/stable/c/9e48844f708eb48bae4e79cb21edc097c966306d commit
- git.kernel.org/stable/c/6a320935fa4293e9e599ec9f85dc9eb3be7029f8 commit
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2026-46040 updated cvss 5.5
kernel: inotify: fix watch count leak when fsnotify_add_inode_mark_locked() fails
-
Red Hat Enterprise Linux 6 perf, kernel, python-perf, kernel-kdump, kernel-firmware, kernel-bootwrapper, +1 moreaffected: no fix planned “Out of support scope”
-
Red Hat Enterprise Linux 8 perf, kernel, bpftool, kernel-rt, kernel-core, kernel-tools, +29 more Red Hat Enterprise Linux 9 rv, perf, rtla, kernel, bpftool, libperf, +83 more Red Hat Enterprise Linux 10 kernelaffected: no fix available “Fix deferred”
-
Red Hat Enterprise Linux 7 perf, kernel, bpftool, kernel-rt, python-perf, kernel-kdump, +8 morenot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
cisa ICSA-26-295-11 updated cvss 0.0
Siemens SIMATIC S7-1500 CPU 1518(F)-4 PN/DP MFP
-
Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AB0) >= 3.1.7 Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP (6ES7518-4AX00-1AC0) >= 3.1.7 Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP (6ES7518-4FX00-1AB0) >= 3.1.7 Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP (6ES7518-4FX00-1AC0) >= 3.1.7 Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP (6AG1518-4AX00-4AC0) >= 3.1.7affected: mitigation, no fix available
Facts from CISA's republication of the vendor's own advisory (CSAF); the linked advisory is the authoritative source. CISA notification · csaf
cisa ICSA-26-295-16 updated cvss 0.0
Siemens SIMATIC S7-1500 TM MFP
-
Siemens SIMATIC S7-1500 TM MFP - GNU/Linux subsystemaffected: mitigation, no fix available
Facts from CISA's republication of the vendor's own advisory (CSAF); the linked advisory is the authoritative source. CISA notification · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
- Assessed
- 3 d ago
Exploit prediction
0.13% chance of exploitation in the next 30 days, higher than 2% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Affected products
- Linux Linux
- Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP
- Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP
- Siemens SIMATIC S7-1500 TM MFP - GNU/Linux subsystem
- Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP
Classification
- Technology feeds
References
-
git.kernel.org
/stable/c/3ab58cf42c46bf2366d2f55ae5c59299d5e178b7
patch
-
git.kernel.org
/stable/c/10edf7e0ffdc7faa18e2244b17722c1b882b8273
patch
-
git.kernel.org
/stable/c/3ad9ccea1b25435f6179b57aa891960beb7ce8f9
patch
-
git.kernel.org
/stable/c/8bcc1cd237ab5ccfdd102869fa031c541943cf40
patch
-
git.kernel.org
/stable/c/73ddc8518a32baff6bc17afda4ee1ebae5b4ed12
patch
-
git.kernel.org
/stable/c/fdaa42ca370d056428e5e171247c8fdce8dff36a
patch
-
git.kernel.org
/stable/c/9e48844f708eb48bae4e79cb21edc097c966306d
patch
-
git.kernel.org
/stable/c/6a320935fa4293e9e599ec9f85dc9eb3be7029f8
patch
- cert-portal.siemens.com /productcert/html/ssa-019113.html
- cert-portal.siemens.com /productcert/html/ssa-457936.html
- cert-portal.siemens.com /productcert/html/ssa-784472.html
Sources
- CVE List CVE-2026-46040
- NVD CVE-2026-46040
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.