{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-99562","id":"CVE-2026-99562","title":"ksmbd: reject FSCTL_SET_ZERO_DATA on a directory handle","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: reject FSCTL_SET_ZERO_DATA on a directory handle\n\nAn authenticated client with a writable tree connection can open a\ndirectory with FILE_WRITE_DATA and send FSCTL_SET_ZERO_DATA on that\nhandle. The handler only checks fp->daccess & FILE_WRITE_DATA_LE, but on\na directory FILE_WRITE_DATA is the legitimate add-file right, so t","descriptionLong":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: reject FSCTL_SET_ZERO_DATA on a directory handle\n\nAn authenticated client with a writable tree connection can open a\ndirectory with FILE_WRITE_DATA and send FSCTL_SET_ZERO_DATA on that\nhandle. The handler only checks fp->daccess & FILE_WRITE_DATA_LE, but on\na directory FILE_WRITE_DATA is the legitimate add-file right, so the\ncheck passes. ksmbd_vfs_zero_data() then calls kernel_write() on the\ndirectory file, which has no FMODE_WRITE, and __kernel_write_iter()\nhits WARN_ON_ONCE(!(file->f_mode & FMODE_WRITE)), panicking a\npanic_on_warn kernel.\n\nBefore commit 25e414db7033 (\"ksmbd: report holes in allocated range\nqueries\") the dense-file path used vfs_fallocate(), which rejects\ndirectories with -EISDIR. The kernel_write() loop that replaced it has\nno such check. Reject a directory handle in ksmbd_vfs_zero_data() before\nwriting, as ksmbd_vfs_write() already does for SMB2_WRITE.\n\n  WARNING: fs/read_write.c:608 at __kernel_write_iter+0x74b/0x8c0\n  Workqueue: ksmbd-io handle_ksmbd_work\n  Call Trace:\n   kernel_write+0x1ef/0x4d0\n   ksmbd_vfs_zero_data+0x413/0x590\n   smb2_ioctl+0x21fa/0x66a0\n   handle_ksmbd_work+0x61b/0x1ff0","published":"2026-11-19T14:45:40.908Z","updated":"2026-11-19T14:45:40.908Z","reserved":"2026-09-25T10:25:14.422Z","status":"PUBLISHED","rejected":false,"assigner":"Linux","metric":null,"metrics":[],"rating":"unrated","products":["Linux"],"affectedProducts":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"25e414db703334954747cb1b3eedf914b093ff8c","lessThan":"89092aa492f1ff8cbbca14503a008795251bae6d","status":"affected","versionType":"git"},{"version":"25e414db703334954747cb1b3eedf914b093ff8c","lessThan":"ef85bad39cf273a8377722c9f3078294dcc2fc7a","status":"affected","versionType":"git"}],"platforms":[]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"7.3","status":"affected"},{"version":"0","lessThan":"7.3","status":"unaffected","versionType":"semver"},{"version":"7.3.2","lessThanOrEqual":"7.3.*","status":"unaffected","versionType":"semver"},{"version":"7.4-rc1","lessThanOrEqual":"*","status":"unaffected","versionType":"original_commit_for_fix"}],"platforms":[]}],"packages":[],"cwes":[],"aliases":[],"references":[{"url":"https://git.kernel.org/stable/c/89092aa492f1ff8cbbca14503a008795251bae6d","tags":[]},{"url":"https://git.kernel.org/stable/c/ef85bad39cf273a8377722c9f3078294dcc2fc7a","tags":[]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":null,"epss":null,"epssPercentile":null,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-99562","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-99562","ok":false,"note":"not found"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-99562","ok":false,"note":"no open-source package data"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-99562","ok":false,"note":"no score yet"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}