{"id":"CVE-2026-139504","state":"PUBLISHED","title":"wifi: mm81x: check bytes_remaining before reading delimiter","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nwifi: mm81x: check bytes_remaining before reading delimiter\n\nmm81x_yaps_hw_read_pkts() reads a full 4-byte delimiter and then\nsubtracts sizeof(delim) from bytes_remaining on every loop iteration,\nguarded only by \"bytes_remaining > 0\". If 1-3 bytes are left in the\nwindow, this reads past the end of the valid data and then subtracts\n4 from a value smaller than 4, driving bytes_remaining negative.\n\nA negative bytes_remaining then reaches the total_len > bytes_remaining\nbranch, where \"bytes_remaining\" is passed to memcpy() as the copy\nlength. Implicitly converted to size_t, a negative int becomes a\nhuge value, turning that memcpy() into a massive out-of-bounds copy.\n\nBail out of the split loop once fewer than sizeof(delim) bytes remain,\nthe same way the existing \"end of stream\" check bails on a zero\ndelimiter.","publishedAt":"2026-11-30T13:35:21.746Z","updatedAt":"2026-11-30T13:35:21.746Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"b1906cea00b021acea22460225401d5b27bc7c36","status":"affected","lessThan":"0f3c6b1b62f3ba755b7b4f5b03335eb91d144f29","versionType":"git"},{"version":"b1906cea00b021acea22460225401d5b27bc7c36","status":"affected","lessThan":"54a54c06868d0c2beb9ec3e2ffda0f6cb33d5c8e","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/wireless/morsemicro/mm81x/yaps_hw.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"7.3","status":"affected"},{"version":"0","status":"unaffected","lessThan":"7.3","versionType":"semver"},{"version":"7.3.6","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc1","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/wireless/morsemicro/mm81x/yaps_hw.c"]}],"references":["https://git.kernel.org/stable/c/0f3c6b1b62f3ba755b7b4f5b03335eb91d144f29","https://git.kernel.org/stable/c/54a54c06868d0c2beb9ec3e2ffda0f6cb33d5c8e"],"weaknesses":[],"ingestedAt":"2026-11-30T13:50:04.417Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/139xxx/CVE-2026-139504.json","commit":"8c2c22940a0de21d18737df980299c0488d5dc73","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-139504","state":"PUBLISHED","datePublished":"2026-11-30T13:35:21.746Z","dateUpdated":"2026-11-30T13:35:21.746Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-11-30T13:22:15.937Z"},"containers":{"cna":{"title":"wifi: mm81x: check bytes_remaining before reading delimiter","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nwifi: mm81x: check bytes_remaining before reading delimiter\n\nmm81x_yaps_hw_read_pkts() reads a full 4-byte delimiter and then\nsubtracts sizeof(delim) from bytes_remaining on every loop iteration,\nguarded only by \"bytes_remaining > 0\". If 1-3 bytes are left in the\nwindow, this reads past the end of the valid data and then subtracts\n4 from a value smaller than 4, driving bytes_remaining negative.\n\nA negative bytes_remaining then reaches the total_len > bytes_remaining\nbranch, where \"bytes_remaining\" is passed to memcpy() as the copy\nlength. Implicitly converted to size_t, a negative int becomes a\nhuge value, turning that memcpy() into a massive out-of-bounds copy.\n\nBail out of the split loop once fewer than sizeof(delim) bytes remain,\nthe same way the existing \"end of stream\" check bails on a zero\ndelimiter."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"b1906cea00b021acea22460225401d5b27bc7c36","status":"affected","lessThan":"0f3c6b1b62f3ba755b7b4f5b03335eb91d144f29","versionType":"git"},{"version":"b1906cea00b021acea22460225401d5b27bc7c36","status":"affected","lessThan":"54a54c06868d0c2beb9ec3e2ffda0f6cb33d5c8e","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/wireless/morsemicro/mm81x/yaps_hw.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"7.3","status":"affected"},{"version":"0","status":"unaffected","lessThan":"7.3","versionType":"semver"},{"version":"7.3.6","status":"unaffected","lessThanOrEqual":"7.3.*","versionType":"semver"},{"version":"7.4-rc1","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/net/wireless/morsemicro/mm81x/yaps_hw.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/0f3c6b1b62f3ba755b7b4f5b03335eb91d144f29"},{"url":"https://git.kernel.org/stable/c/54a54c06868d0c2beb9ec3e2ffda0f6cb33d5c8e"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-11-30T13:35:21.746Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"7.3","versionEndExcluding":"7.3.6"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"7.3","versionEndExcluding":"7.4-rc1"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}