{"id":"CVE-2025-37947","published":"2025-05-20T16:01:43Z","modified":"2026-08-05T11:58:33Z","title":"ksmbd: prevent out-of-bounds stream writes by validating *pos","vendor":"Linux","product":"Linux","tier":"tail","description":{"text":"In the Linux kernel, the following vulnerability has been resolved:\n\nksmbd: prevent out-of-bounds stream writes by validating *pos\n\nksmbd_vfs_stream_write() did not validate whether the write offset\n(*pos) was within the bounds of the existing stream data length (v_len).\nIf *pos was greater than or equal to v_len, this could lead to an\nout-of-bounds memory write.\n\nThis patch adds a check to ensure *pos is less than v_len before\nproceeding. If the condition fails, -EINVAL is returned.","provenance":"source","from":"CVE.org"},"cvss":{"score":8.8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00823,"percentile":0.54423,"provenance":"source"},"cwes":[{"id":"CWE-787","name":"Out-of-bounds Write"}],"references":[{"url":"https://git.kernel.org/stable/c/7f61da79df86fd140c7768e668ad846bfa7ec8e1","tags":[]},{"url":"https://git.kernel.org/stable/c/04c8a38c60346bb5a7c49b276de7233f703ce9cb","tags":[]},{"url":"https://git.kernel.org/stable/c/d62ba16563a86aae052f96d270b3b6f78fca154c","tags":[]},{"url":"https://git.kernel.org/stable/c/e6356499fd216ed6343ae0363f4c9303f02c5034","tags":[]},{"url":"https://git.kernel.org/stable/c/0ca6df4f40cf4c32487944aaf48319cb6c25accc","tags":[]},{"url":"https://github.com/doyensec/KSMBD-CVE-2025-37947/blob/main/CVE-2025-37947.c","tags":["exploit"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/08/msg00010.html","tags":[]}],"priority":{"score":22.0,"factors":[{"name":"EPSS percentile","points":10.88},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":6.16}]},"exploitSources":{"pocGithub":{"count":1,"skipped":0,"earliest":"2025-10-03","earliestUrl":"https://github.com/doyensec/KSMBD-CVE-2025-37947","repos":[{"name":"doyensec/KSMBD-CVE-2025-37947","url":"https://github.com/doyensec/KSMBD-CVE-2025-37947","stars":21,"created":"2025-10-03"}]},"first":{"date":"2025-10-03","source":"PoC-in-GitHub","url":"https://github.com/doyensec/KSMBD-CVE-2025-37947"},"provenance":"source"},"vendorSlug":"linux","affectedVersions":[{"vendor":"Linux","product":"Linux","versions":[">= 0626e6641f6b467447c81dd7678a69c66f7746cf, < 7f61da79df86fd140c7768e668ad846bfa7ec8e1",">= 0626e6641f6b467447c81dd7678a69c66f7746cf, < 04c8a38c60346bb5a7c49b276de7233f703ce9cb",">= 0626e6641f6b467447c81dd7678a69c66f7746cf, < d62ba16563a86aae052f96d270b3b6f78fca154c",">= 0626e6641f6b467447c81dd7678a69c66f7746cf, < e6356499fd216ed6343ae0363f4c9303f02c5034",">= 0626e6641f6b467447c81dd7678a69c66f7746cf, < 0ca6df4f40cf4c32487944aaf48319cb6c25accc"]},{"vendor":"Linux","product":"Linux","versions":["5.15"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total","timestamp":"2025-10-10T03:55:20.529301Z","from":"CISA ADP","provenance":"source"},"euvd":{"id":"EUVD-2025-15903","exploited":false,"provenance":"source"},"exploitRefs":["https://github.com/doyensec/KSMBD-CVE-2025-37947/blob/main/CVE-2025-37947.c"]}