{"id":"CVE-2023-53553","state":"PUBLISHED","title":"HID: hyperv: avoid struct memcpy overrun warning","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: hyperv: avoid struct memcpy overrun warning\n\nA previous patch addressed the fortified memcpy warning for most\nbuilds, but I still see this one with gcc-9:\n\nIn file included from include/linux/string.h:254,\n                 from drivers/hid/hid-hyperv.c:8:\nIn function 'fortify_memcpy_chk',\n    inlined from 'mousevsc_on_receive' at drivers/hid/hid-hyperv.c:272:3:\ninclude/linux/fortify-string.h:583:4: error: call to '__write_overflow_field' declared with attribute warning: detected write beyond size of field (1st parameter); maybe use struct_group()? [-Werror=attribute-warning]\n  583 |    __write_overflow_field(p_size_field, size);\n      |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nMy guess is that the WARN_ON() itself is what confuses gcc, so it no\nlonger sees that there is a correct range check. Rework the code in a\nway that helps readability and avoids the warning.","publishedAt":"2025-10-04T15:16:59.091Z","updatedAt":"2026-05-11T19:47:11.954Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"542f25a94471570e2594be5b422b9ca572cf88a1","status":"affected","lessThan":"a7902cc5f5b9c95997017c8e309da760fb1deb6e","versionType":"git"},{"version":"542f25a94471570e2594be5b422b9ca572cf88a1","status":"affected","lessThan":"5f151364b1da6bd217632fd4ee8cc24eaf66a497","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/hid/hid-hyperv.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.2","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.2","versionType":"semver"},{"version":"6.4.5","status":"unaffected","lessThanOrEqual":"6.4.*","versionType":"semver"},{"version":"6.5","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/hid/hid-hyperv.c"]}],"references":["https://git.kernel.org/stable/c/a7902cc5f5b9c95997017c8e309da760fb1deb6e","https://git.kernel.org/stable/c/5f151364b1da6bd217632fd4ee8cc24eaf66a497"],"weaknesses":[],"ingestedAt":"2026-10-29T20:06:33.064Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2023/53xxx/CVE-2023-53553.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2023-53553","state":"PUBLISHED","datePublished":"2025-10-04T15:16:59.091Z","dateUpdated":"2026-05-11T19:47:11.954Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-10-04T15:14:15.922Z"},"containers":{"cna":{"title":"HID: hyperv: avoid struct memcpy overrun warning","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: hyperv: avoid struct memcpy overrun warning\n\nA previous patch addressed the fortified memcpy warning for most\nbuilds, but I still see this one with gcc-9:\n\nIn file included from include/linux/string.h:254,\n                 from drivers/hid/hid-hyperv.c:8:\nIn function 'fortify_memcpy_chk',\n    inlined from 'mousevsc_on_receive' at drivers/hid/hid-hyperv.c:272:3:\ninclude/linux/fortify-string.h:583:4: error: call to '__write_overflow_field' declared with attribute warning: detected write beyond size of field (1st parameter); maybe use struct_group()? [-Werror=attribute-warning]\n  583 |    __write_overflow_field(p_size_field, size);\n      |    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nMy guess is that the WARN_ON() itself is what confuses gcc, so it no\nlonger sees that there is a correct range check. Rework the code in a\nway that helps readability and avoids the warning."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"542f25a94471570e2594be5b422b9ca572cf88a1","status":"affected","lessThan":"a7902cc5f5b9c95997017c8e309da760fb1deb6e","versionType":"git"},{"version":"542f25a94471570e2594be5b422b9ca572cf88a1","status":"affected","lessThan":"5f151364b1da6bd217632fd4ee8cc24eaf66a497","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/hid/hid-hyperv.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.2","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.2","versionType":"semver"},{"version":"6.4.5","status":"unaffected","lessThanOrEqual":"6.4.*","versionType":"semver"},{"version":"6.5","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/hid/hid-hyperv.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/a7902cc5f5b9c95997017c8e309da760fb1deb6e"},{"url":"https://git.kernel.org/stable/c/5f151364b1da6bd217632fd4ee8cc24eaf66a497"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T19:47:11.954Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.2","versionEndExcluding":"6.4.5"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.2","versionEndExcluding":"6.5"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}