{"api_version":"1","generated_at":"2026-10-22T01:15:59+00:00","cve":"CVE-2026-98645","urls":{"html":"https://cve.report/CVE-2026-98645","api":"https://cve.report/api/cve/CVE-2026-98645.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2026-98645","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2026-98645"},"summary":{"title":"HID: winwing: fix use-after-free in force feedback teardown","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: winwing: fix use-after-free in force feedback teardown\n\nwinwing_init_ff() passes the driver's private data, allocated with\ndevm_kzalloc() in winwing_probe(), as the effect context to\ninput_ff_create_memless(). The memoryless force-feedback core takes\nownership of that pointer and frees it with kfree() from\ninput_ff_destroy() (ml_ff_destroy()) when the input device is\ndestroyed.\n\nFreeing a devm-managed allocation with kfree() is an invalid free, and\nthe same object is then released again by devres when the HID device is\ntorn down, a double free. As the allocation also embeds the LED class\ndevices, their timers and work item live on freed memory and the slab\ngets corrupted. This triggers on unbind, rmmod, hot-unplug and on system\nsuspend, where the firmware cache walks the now-corrupt devres list.\nKASAN reports:\n\n  BUG: KASAN: invalid-free in input_ff_destroy\n  Allocated by task N:\n    winwing_probe\n\nPass NULL as the memless context instead and fetch the driver data from\nthe input device in winwing_play_effect(): the HID core already stores\nthe hid_device as the input device's drvdata. The force-feedback core\nthen owns nothing that it must not free.","state":"PUBLISHED","assigner":"Linux","published_at":"2026-10-18 16:17:17","updated_at":"2026-10-19 10:19:28"},"problem_types":[],"metrics":[],"references":[{"url":"https://git.kernel.org/stable/c/2b25f11ec52ea0a82334d5b83ee321f6b0a35923","name":"https://git.kernel.org/stable/c/2b25f11ec52ea0a82334d5b83ee321f6b0a35923","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/a1a5ad37e50ceb192c07ac7e2d7143638cd4d110","name":"https://git.kernel.org/stable/c/a1a5ad37e50ceb192c07ac7e2d7143638cd4d110","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-98645","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-98645","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 42d020b54edc57d03749bed75976f1e962a9fbfa 2b25f11ec52ea0a82334d5b83ee321f6b0a35923 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 42d020b54edc57d03749bed75976f1e962a9fbfa a1a5ad37e50ceb192c07ac7e2d7143638cd4d110 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 7.1","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.1 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.2.9 7.2.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.3 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["drivers/hid/hid-winwing.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"2b25f11ec52ea0a82334d5b83ee321f6b0a35923","status":"affected","version":"42d020b54edc57d03749bed75976f1e962a9fbfa","versionType":"git"},{"lessThan":"a1a5ad37e50ceb192c07ac7e2d7143638cd4d110","status":"affected","version":"42d020b54edc57d03749bed75976f1e962a9fbfa","versionType":"git"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["drivers/hid/hid-winwing.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"status":"affected","version":"7.1"},{"lessThan":"7.1","status":"unaffected","version":"0","versionType":"semver"},{"lessThanOrEqual":"7.2.*","status":"unaffected","version":"7.2.9","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"7.3","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.2.9","versionStartIncluding":"7.1","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.3","versionStartIncluding":"7.1","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: winwing: fix use-after-free in force feedback teardown\n\nwinwing_init_ff() passes the driver's private data, allocated with\ndevm_kzalloc() in winwing_probe(), as the effect context to\ninput_ff_create_memless(). The memoryless force-feedback core takes\nownership of that pointer and frees it with kfree() from\ninput_ff_destroy() (ml_ff_destroy()) when the input device is\ndestroyed.\n\nFreeing a devm-managed allocation with kfree() is an invalid free, and\nthe same object is then released again by devres when the HID device is\ntorn down, a double free. As the allocation also embeds the LED class\ndevices, their timers and work item live on freed memory and the slab\ngets corrupted. This triggers on unbind, rmmod, hot-unplug and on system\nsuspend, where the firmware cache walks the now-corrupt devres list.\nKASAN reports:\n\n  BUG: KASAN: invalid-free in input_ff_destroy\n  Allocated by task N:\n    winwing_probe\n\nPass NULL as the memless context instead and fetch the driver data from\nthe input device in winwing_play_effect(): the HID core already stores\nthe hid_device as the input device's drvdata. The force-feedback core\nthen owns nothing that it must not free."}],"providerMetadata":{"dateUpdated":"2026-10-19T09:23:14.926Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/2b25f11ec52ea0a82334d5b83ee321f6b0a35923"},{"url":"https://git.kernel.org/stable/c/a1a5ad37e50ceb192c07ac7e2d7143638cd4d110"}],"title":"HID: winwing: fix use-after-free in force feedback teardown","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2026-98645","datePublished":"2026-10-18T15:20:16.676Z","dateReserved":"2026-09-25T10:25:14.362Z","dateUpdated":"2026-10-19T09:23:14.926Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"},"nvd":{"publishedDate":"2026-10-18 16:17:17","lastModifiedDate":"2026-10-19 10:19:28","problem_types":[],"metrics":[],"configurations":[]},"legacy_mitre":{"record":{"CveYear":"2026","CveId":"98645","Ordinal":"1","Title":"HID: winwing: fix use-after-free in force feedback teardown","CVE":"CVE-2026-98645","Year":"2026"},"notes":[{"CveYear":"2026","CveId":"98645","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nHID: winwing: fix use-after-free in force feedback teardown\n\nwinwing_init_ff() passes the driver's private data, allocated with\ndevm_kzalloc() in winwing_probe(), as the effect context to\ninput_ff_create_memless(). The memoryless force-feedback core takes\nownership of that pointer and frees it with kfree() from\ninput_ff_destroy() (ml_ff_destroy()) when the input device is\ndestroyed.\n\nFreeing a devm-managed allocation with kfree() is an invalid free, and\nthe same object is then released again by devres when the HID device is\ntorn down, a double free. As the allocation also embeds the LED class\ndevices, their timers and work item live on freed memory and the slab\ngets corrupted. This triggers on unbind, rmmod, hot-unplug and on system\nsuspend, where the firmware cache walks the now-corrupt devres list.\nKASAN reports:\n\n  BUG: KASAN: invalid-free in input_ff_destroy\n  Allocated by task N:\n    winwing_probe\n\nPass NULL as the memless context instead and fetch the driver data from\nthe input device in winwing_play_effect(): the HID core already stores\nthe hid_device as the input device's drvdata. The force-feedback core\nthen owns nothing that it must not free.","Type":"Description","Title":"HID: winwing: fix use-after-free in force feedback teardown"}]}}}