{"id":"CVE-2026-99469","state":"PUBLISHED","title":"media: gspca: use vb2_video_unregister_device() on disconnect","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nmedia: gspca: use vb2_video_unregister_device() on disconnect\n\ngspca uses vb2_fop_release(), but gspca_disconnect() only unregisters\nthe video device. If the queue owner closes the device after USB\ndisconnect, vb2_fop_release() releases the queue and invokes\ngspca_stop_streaming() at that point.\n\ngspca_stream_off() calls subdriver stop callbacks and\nusb_set_interface() through gspca_dev->dev. By the time the late close\nruns, the USB core can have freed the usb_device, resulting in a\nuse-after-free. This was observed as a KASAN use-after-free in sd_stopN().\n\nUse vb2_video_unregister_device() so the queue is released and streaming\nis stopped synchronously during disconnect, while the usb_device is still\nvalid. Since the helper takes the queue lock, which is usb_lock, call it\nafter dropping that lock.","publishedAt":"2026-11-19T14:42:55.312Z","updatedAt":"2026-11-19T14:42:55.312Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"fda9ca3cbee24f6e48c04946a8d2f66565d2d4b2","versionType":"git"},{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"d02a2ed057372d3739ab23d778fc4e04d3330513","versionType":"git"},{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"f6b21af3e32f142bf3e591dbb10044c60472f716","versionType":"git"},{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"3dbbbc3cafa2de377d9b97af4e35b8b6b5282047","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/media/usb/gspca/gspca.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.10","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.10","versionType":"semver"},{"version":"6.12.117","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.61","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.2","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/media/usb/gspca/gspca.c"]}],"references":["https://git.kernel.org/stable/c/fda9ca3cbee24f6e48c04946a8d2f66565d2d4b2","https://git.kernel.org/stable/c/d02a2ed057372d3739ab23d778fc4e04d3330513","https://git.kernel.org/stable/c/f6b21af3e32f142bf3e591dbb10044c60472f716","https://git.kernel.org/stable/c/3dbbbc3cafa2de377d9b97af4e35b8b6b5282047"],"weaknesses":[],"ingestedAt":"2026-11-19T14:48:06.147Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/99xxx/CVE-2026-99469.json","commit":"783f6d4140a34eaf92c5bfee971cfe497fa6394e","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-99469","state":"PUBLISHED","datePublished":"2026-11-19T14:42:55.312Z","dateUpdated":"2026-11-19T14:42:55.312Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-09-25T10:25:14.417Z"},"containers":{"cna":{"title":"media: gspca: use vb2_video_unregister_device() on disconnect","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nmedia: gspca: use vb2_video_unregister_device() on disconnect\n\ngspca uses vb2_fop_release(), but gspca_disconnect() only unregisters\nthe video device. If the queue owner closes the device after USB\ndisconnect, vb2_fop_release() releases the queue and invokes\ngspca_stop_streaming() at that point.\n\ngspca_stream_off() calls subdriver stop callbacks and\nusb_set_interface() through gspca_dev->dev. By the time the late close\nruns, the USB core can have freed the usb_device, resulting in a\nuse-after-free. This was observed as a KASAN use-after-free in sd_stopN().\n\nUse vb2_video_unregister_device() so the queue is released and streaming\nis stopped synchronously during disconnect, while the usb_device is still\nvalid. Since the helper takes the queue lock, which is usb_lock, call it\nafter dropping that lock."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"fda9ca3cbee24f6e48c04946a8d2f66565d2d4b2","versionType":"git"},{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"d02a2ed057372d3739ab23d778fc4e04d3330513","versionType":"git"},{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"f6b21af3e32f142bf3e591dbb10044c60472f716","versionType":"git"},{"version":"f729ef5796d82a95758d9edc7eea5879a3a12b25","status":"affected","lessThan":"3dbbbc3cafa2de377d9b97af4e35b8b6b5282047","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/media/usb/gspca/gspca.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.10","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.10","versionType":"semver"},{"version":"6.12.117","status":"unaffected","lessThanOrEqual":"6.12.*","versionType":"semver"},{"version":"6.18.61","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"7.3.2","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/media/usb/gspca/gspca.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/fda9ca3cbee24f6e48c04946a8d2f66565d2d4b2"},{"url":"https://git.kernel.org/stable/c/d02a2ed057372d3739ab23d778fc4e04d3330513"},{"url":"https://git.kernel.org/stable/c/f6b21af3e32f142bf3e591dbb10044c60472f716"},{"url":"https://git.kernel.org/stable/c/3dbbbc3cafa2de377d9b97af4e35b8b6b5282047"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-11-19T14:42:55.312Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.10","versionEndExcluding":"6.12.117"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.10","versionEndExcluding":"6.18.61"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.10","versionEndExcluding":"7.3.2"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.10","versionEndExcluding":"7.4-rc1"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}