{"id":"CVE-2026-31694","state":"PUBLISHED","title":"fuse: reject oversized dirents in page cache","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nfuse: reject oversized dirents in page cache\n\nfuse_add_dirent_to_cache() computes a serialized dirent size from the\nserver-controlled namelen field and copies the dirent into a single\npage-cache page. The existing logic only checks whether the dirent fits\nin the remaining space of the current page and advances to a fresh page\nif not. It never checks whether the dirent itself exceeds PAGE_SIZE.\n\nAs a result, a malicious FUSE server can return a dirent with\nnamelen=4095, producing a serialized record size of 4120 bytes. On 4 KiB\npage systems this causes memcpy() to overflow the cache page by 24 bytes\ninto the following kernel page.\n\nReject dirents that cannot fit in a single page before copying them into\nthe readdir cache.","publishedAt":"2026-05-01T13:53:36.048Z","updatedAt":"2026-10-15T01:17:53.619Z","severity":{"score":7.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"27992ef80770d61a57f6c3a551735b08cefdffa3","status":"affected","lessThan":"7de93abfaae1b2dc94da8a07a36421bd073f1d8f","versionType":"git"},{"version":"27992ef80770d61a57f6c3a551735b08cefdffa3","status":"affected","lessThan":"474ce83c96a55f2eeb14dee2be375eeadfdacdf5","versionType":"git"},{"version":"27992ef80770d61a57f6c3a551735b08cefdffa3","status":"affected","lessThan":"51a8de6c50bf947c8f534cd73da4c8f0a13e7bed","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/fuse/readdir.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.15","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.15","versionType":"semver"},{"version":"6.18.25","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.0.2","status":"unaffected","lessThanOrEqual":"7.0.*","versionType":"semver"},{"version":"7.1","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/fuse/readdir.c"]}],"references":["https://git.kernel.org/stable/c/7de93abfaae1b2dc94da8a07a36421bd073f1d8f","https://git.kernel.org/stable/c/474ce83c96a55f2eeb14dee2be375eeadfdacdf5","https://git.kernel.org/stable/c/51a8de6c50bf947c8f534cd73da4c8f0a13e7bed","https://cert-portal.siemens.com/productcert/html/ssa-784472.html"],"weaknesses":[],"ingestedAt":"2026-10-29T20:11:40.391Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/31xxx/CVE-2026-31694.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-31694","state":"PUBLISHED","datePublished":"2026-05-01T13:53:36.048Z","dateUpdated":"2026-10-15T01:17:53.619Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-03-09T15:48:24.131Z"},"containers":{"cna":{"title":"fuse: reject oversized dirents in page cache","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nfuse: reject oversized dirents in page cache\n\nfuse_add_dirent_to_cache() computes a serialized dirent size from the\nserver-controlled namelen field and copies the dirent into a single\npage-cache page. The existing logic only checks whether the dirent fits\nin the remaining space of the current page and advances to a fresh page\nif not. It never checks whether the dirent itself exceeds PAGE_SIZE.\n\nAs a result, a malicious FUSE server can return a dirent with\nnamelen=4095, producing a serialized record size of 4120 bytes. On 4 KiB\npage systems this causes memcpy() to overflow the cache page by 24 bytes\ninto the following kernel page.\n\nReject dirents that cannot fit in a single page before copying them into\nthe readdir cache."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"27992ef80770d61a57f6c3a551735b08cefdffa3","status":"affected","lessThan":"7de93abfaae1b2dc94da8a07a36421bd073f1d8f","versionType":"git"},{"version":"27992ef80770d61a57f6c3a551735b08cefdffa3","status":"affected","lessThan":"474ce83c96a55f2eeb14dee2be375eeadfdacdf5","versionType":"git"},{"version":"27992ef80770d61a57f6c3a551735b08cefdffa3","status":"affected","lessThan":"51a8de6c50bf947c8f534cd73da4c8f0a13e7bed","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/fuse/readdir.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.15","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.15","versionType":"semver"},{"version":"6.18.25","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.0.2","status":"unaffected","lessThanOrEqual":"7.0.*","versionType":"semver"},{"version":"7.1","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/fuse/readdir.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/7de93abfaae1b2dc94da8a07a36421bd073f1d8f"},{"url":"https://git.kernel.org/stable/c/474ce83c96a55f2eeb14dee2be375eeadfdacdf5"},{"url":"https://git.kernel.org/stable/c/51a8de6c50bf947c8f534cd73da4c8f0a13e7bed"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The vulnerable path is reached through local filesystem operations on a FUSE mount, with malicious replies supplied via a local /dev/fuse userspace daemon rather than directly by network packets.\nAC:L - A malicious FUSE server can deterministically set FOPEN_CACHE_DIR and return a dirent with namelen=4095; the overflow occurs during ordinary readdir/getdents on common 4 KiB page systems.\nPR:L - An unprivileged local user can plausibly run and access their own FUSE filesystem, including through user-namespace-capable FUSE mounts where available, and does not need real init-namespace root.\nUI:N - The malicious local mounter can trigger getdents/readdir on their own FUSE directory without requiring a separate victim action.\nS:U - The bug is kernel memory corruption within the same host kernel security authority and does not cross a VM, IOMMU, or similar scope boundary.\nC:H - The bug is an attacker-controlled out-of-bounds write into the following kernel page, and such kernel memory corruption can be leveraged to expose sensitive kernel or process memory.\nI:H - The attacker controls the oversized serialized dirent bytes copied past the cache page, giving a kernel memory corruption primitive that can plausibly be developed into arbitrary modification or code execution.\nA:H - The overflow can corrupt adjacent kernel memory or fault during the memcpy/kmap access path, making kernel oops, panic, or system instability a high-impact availability outcome."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T12:24:32.263Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.15","versionEndExcluding":"6.18.25"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.15","versionEndExcluding":"7.0.2"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.15","versionEndExcluding":"7.1"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"affected":[{"vendor":"Siemens","product":"SIMATIC S7-1500 TM MFP - GNU/Linux subsystem","defaultStatus":"unknown","versions":[{"version":"0","status":"affected","lessThan":"*","versionType":"custom"}]}],"references":[{"url":"https://cert-portal.siemens.com/productcert/html/ssa-784472.html"}],"providerMetadata":{"shortName":"siemens-SADP","orgId":"0b142b55-0307-4c5a-b3c9-f314f3fb7c5e","dateUpdated":"2026-10-15T01:17:53.619Z"},"x_adpType":"supplier"}]}}}