{"id":"CVE-2026-143107","state":"PUBLISHED","title":"fs/proc: fix the write length returned by proc_sys_call_handler()","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nfs/proc: fix the write length returned by proc_sys_call_handler()\n\nproc_sys_call_handler() reads the write length from iov_iter_count() and\ncopies that many bytes from the iterator into kbuf.  A cgroup/sysctl BPF\nprogram can replace the new value through bpf_sysctl_set_new_value() and\nupdate count to the length of the replacement value.  The handler then\nreturns that adjusted count as the number of bytes written, even though\nthe iterator originally held a different number of bytes.\n\nIf the replacement value is longer than the original input, ->write_iter()\nreports more bytes than the iterator held.  splice(2) passes that value to\niter_file_splice_write(), which subtracts it from the pipe length and\nwalks past the pipe head:\n\n  Splice Exceeded! ret=7 tot=1 left=0\n  Oops: general protection fault\n  RIP: 0010:iter_file_splice_write+0xb6f/0x1170\n\nThe write path consumes at most the original iterator length in\ncopy_from_iter_full() before the BPF hook runs.  Return the smaller of the\nadjusted and original counts on the write path, so an expanded BPF value\ncannot exceed the iterator while a handler that reports a shorter parsed\nlength still produces a short write.  The read path keeps using the\nadjusted count for copy_to_iter().","publishedAt":"2026-12-03T09:19:23.749Z","updatedAt":"2026-12-03T09:19:23.749Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"5bbe4236551e90b6dc1726c1dc90938c983019f4","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"320b18a1d5fc8e3d1c0bc9bc85bad9f385febe02","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"d53648ba26a19a7b9941baeaf29e3ce5eccda467","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"ff5b00fdf78b7bd95b651beb9ea704a0be8d5be7","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"c8384cc688e7c22ad955369dad56e98503b93f82","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"fbdc020ee1b82079102e493aaa7200de5f497a38","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/proc/proc_sysctl.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.2","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.2","versionType":"semver"},{"version":"5.10.276","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.227","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.12.120","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.66","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.7","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/proc/proc_sysctl.c"]}],"references":["https://git.kernel.org/stable/c/5bbe4236551e90b6dc1726c1dc90938c983019f4","https://git.kernel.org/stable/c/320b18a1d5fc8e3d1c0bc9bc85bad9f385febe02","https://git.kernel.org/stable/c/d53648ba26a19a7b9941baeaf29e3ce5eccda467","https://git.kernel.org/stable/c/ff5b00fdf78b7bd95b651beb9ea704a0be8d5be7","https://git.kernel.org/stable/c/c8384cc688e7c22ad955369dad56e98503b93f82","https://git.kernel.org/stable/c/fbdc020ee1b82079102e493aaa7200de5f497a38"],"weaknesses":[],"ingestedAt":"2026-12-03T09:28:04.553Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/143xxx/CVE-2026-143107.json","commit":"9fd484e43f2e14021809e195d28c1172759faad0","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-143107","state":"PUBLISHED","datePublished":"2026-12-03T09:19:23.749Z","dateUpdated":"2026-12-03T09:19:23.749Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-12-03T03:10:28.349Z"},"containers":{"cna":{"title":"fs/proc: fix the write length returned by proc_sys_call_handler()","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nfs/proc: fix the write length returned by proc_sys_call_handler()\n\nproc_sys_call_handler() reads the write length from iov_iter_count() and\ncopies that many bytes from the iterator into kbuf.  A cgroup/sysctl BPF\nprogram can replace the new value through bpf_sysctl_set_new_value() and\nupdate count to the length of the replacement value.  The handler then\nreturns that adjusted count as the number of bytes written, even though\nthe iterator originally held a different number of bytes.\n\nIf the replacement value is longer than the original input, ->write_iter()\nreports more bytes than the iterator held.  splice(2) passes that value to\niter_file_splice_write(), which subtracts it from the pipe length and\nwalks past the pipe head:\n\n  Splice Exceeded! ret=7 tot=1 left=0\n  Oops: general protection fault\n  RIP: 0010:iter_file_splice_write+0xb6f/0x1170\n\nThe write path consumes at most the original iterator length in\ncopy_from_iter_full() before the BPF hook runs.  Return the smaller of the\nadjusted and original counts on the write path, so an expanded BPF value\ncannot exceed the iterator while a handler that reports a shorter parsed\nlength still produces a short write.  The read path keeps using the\nadjusted count for copy_to_iter()."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"5bbe4236551e90b6dc1726c1dc90938c983019f4","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"320b18a1d5fc8e3d1c0bc9bc85bad9f385febe02","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"d53648ba26a19a7b9941baeaf29e3ce5eccda467","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"ff5b00fdf78b7bd95b651beb9ea704a0be8d5be7","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"c8384cc688e7c22ad955369dad56e98503b93f82","versionType":"git"},{"version":"4e63acdff864654cee0ac5aaeda3913798ee78f6","status":"affected","lessThan":"fbdc020ee1b82079102e493aaa7200de5f497a38","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/proc/proc_sysctl.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.2","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.2","versionType":"semver"},{"version":"5.10.276","status":"unaffected","lessThanOrEqual":"5.10.*","versionType":"semver"},{"version":"5.15.227","status":"unaffected","lessThanOrEqual":"5.15.*","versionType":"semver"},{"version":"6.12.120","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.66","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.7","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc3","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["fs/proc/proc_sysctl.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/5bbe4236551e90b6dc1726c1dc90938c983019f4"},{"url":"https://git.kernel.org/stable/c/320b18a1d5fc8e3d1c0bc9bc85bad9f385febe02"},{"url":"https://git.kernel.org/stable/c/d53648ba26a19a7b9941baeaf29e3ce5eccda467"},{"url":"https://git.kernel.org/stable/c/ff5b00fdf78b7bd95b651beb9ea704a0be8d5be7"},{"url":"https://git.kernel.org/stable/c/c8384cc688e7c22ad955369dad56e98503b93f82"},{"url":"https://git.kernel.org/stable/c/fbdc020ee1b82079102e493aaa7200de5f497a38"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-12-03T09:19:23.749Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.2","versionEndExcluding":"5.10.276"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.2","versionEndExcluding":"5.15.227"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.2","versionEndExcluding":"6.12.120"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.2","versionEndExcluding":"6.18.66"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.2","versionEndExcluding":"7.3.7"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.2","versionEndExcluding":"7.4-rc3"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}