{ "dataType": "CVE_RECORD", "dataVersion": "5.2", "cveMetadata": { "cveId": "CVE-2023-53693", "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "state": "PUBLISHED", "assignerShortName": "Linux", "dateReserved": "2025-10-22T13:21:37.344Z", "datePublished": "2025-10-22T13:23:35.280Z", "dateUpdated": "2026-05-11T19:50:01.014Z" }, "containers": { "cna": { "providerMetadata": { "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67", "shortName": "Linux", "dateUpdated": "2026-05-11T19:50:01.014Z" }, "descriptions": [ { "lang": "en", "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nUSB: gadget: Fix the memory leak in raw_gadget driver\n\nCurrently, increasing raw_dev->count happens before invoke the\nraw_queue_event(), if the raw_queue_event() return error, invoke\nraw_release() will not trigger the dev_free() to be called.\n\n[ 268.905865][ T5067] raw-gadget.0 gadget.0: failed to queue event\n[ 268.912053][ T5067] udc dummy_udc.0: failed to start USB Raw Gadget: -12\n[ 268.918885][ T5067] raw-gadget.0: probe of gadget.0 failed with error -12\n[ 268.925956][ T5067] UDC core: USB Raw Gadget: couldn't find an available UDC or it's busy\n[ 268.934657][ T5067] misc raw-gadget: fail, usb_gadget_register_driver returned -16\n\nBUG: memory leak\n\n[] kmalloc_trace+0x24/0x90 mm/slab_common.c:1076\n[] kmalloc include/linux/slab.h:582 [inline]\n[] kzalloc include/linux/slab.h:703 [inline]\n[] dev_new drivers/usb/gadget/legacy/raw_gadget.c:191 [inline]\n[] raw_open+0x45/0x110 drivers/usb/gadget/legacy/raw_gadget.c:385\n[] misc_open+0x1a9/0x1f0 drivers/char/misc.c:165\n\n[] kmalloc_trace+0x24/0x90 mm/slab_common.c:1076\n[] kmalloc include/linux/slab.h:582 [inline]\n[] raw_ioctl_init+0xdf/0x410 drivers/usb/gadget/legacy/raw_gadget.c:460\n[] raw_ioctl+0x5f9/0x1120 drivers/usb/gadget/legacy/raw_gadget.c:1250\n[] vfs_ioctl fs/ioctl.c:51 [inline]\n\n[] kmalloc_trace+0x24/0x90 mm/slab_common.c:1076\n[] kmalloc include/linux/slab.h:582 [inline]\n[] kzalloc include/linux/slab.h:703 [inline]\n[] dummy_alloc_request+0x5a/0xe0 drivers/usb/gadget/udc/dummy_hcd.c:665\n[] usb_ep_alloc_request+0x22/0xd0 drivers/usb/gadget/udc/core.c:196\n[] gadget_bind+0x6d/0x370 drivers/usb/gadget/legacy/raw_gadget.c:292\n\nThis commit therefore invoke kref_get() under the condition that\nraw_queue_event() return success." } ], "affected": [ { "product": "Linux", "vendor": "Linux", "defaultStatus": "unaffected", "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git", "programFiles": [ "drivers/usb/gadget/legacy/raw_gadget.c" ], "versions": [ { "version": "f2c2e717642c66f7fe7e5dd69b2e8ff5849f4d10", "lessThan": "68e6287ac61dc22513cd39f02b9ac1fef28513e4", "status": "affected", "versionType": "git" }, { "version": "f2c2e717642c66f7fe7e5dd69b2e8ff5849f4d10", "lessThan": "0f7a2b567197798da7bfa2252f4485c0ca6c6266", "status": "affected", "versionType": "git" }, { "version": "f2c2e717642c66f7fe7e5dd69b2e8ff5849f4d10", "lessThan": "de77000c1923d7942f9b4f08447c8feeae1c0f33", "status": "affected", "versionType": "git" }, { "version": "f2c2e717642c66f7fe7e5dd69b2e8ff5849f4d10", "lessThan": "9934e5d07c0dc294169a7d52f6309f35cd6d7755", "status": "affected", "versionType": "git" }, { "version": "f2c2e717642c66f7fe7e5dd69b2e8ff5849f4d10", "lessThan": "83e30f2bf86ef7c38fbd476ed81a88522b620628", "status": "affected", "versionType": "git" } ] }, { "product": "Linux", "vendor": "Linux", "defaultStatus": "affected", "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git", "programFiles": [ "drivers/usb/gadget/legacy/raw_gadget.c" ], "versions": [ { "version": "5.7", "status": "affected" }, { "version": "0", "lessThan": "5.7", "status": "unaffected", "versionType": "semver" }, { "version": "5.10.190", "lessThanOrEqual": "5.10.*", "status": "unaffected", "versionType": "semver" }, { "version": "5.15.124", "lessThanOrEqual": "5.15.*", "status": "unaffected", "versionType": "semver" }, { "version": "6.1.43", "lessThanOrEqual": "6.1.*", "status": "unaffected", "versionType": "semver" }, { "version": "6.4.8", "lessThanOrEqual": "6.4.*", "status": "unaffected", "versionType": "semver" }, { "version": "6.5", "lessThanOrEqual": "*", "status": "unaffected", "versionType": "original_commit_for_fix" } ] } ], "cpeApplicability": [ { "nodes": [ { "operator": "OR", "negate": false, "cpeMatch": [ { "vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.7", "versionEndExcluding": "5.10.190" }, { "vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.7", "versionEndExcluding": "5.15.124" }, { "vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.7", "versionEndExcluding": "6.1.43" }, { "vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.7", "versionEndExcluding": "6.4.8" }, { "vulnerable": true, "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*", "versionStartIncluding": "5.7", "versionEndExcluding": "6.5" } ] } ] } ], "references": [ { "url": "https://git.kernel.org/stable/c/68e6287ac61dc22513cd39f02b9ac1fef28513e4" }, { "url": "https://git.kernel.org/stable/c/0f7a2b567197798da7bfa2252f4485c0ca6c6266" }, { "url": "https://git.kernel.org/stable/c/de77000c1923d7942f9b4f08447c8feeae1c0f33" }, { "url": "https://git.kernel.org/stable/c/9934e5d07c0dc294169a7d52f6309f35cd6d7755" }, { "url": "https://git.kernel.org/stable/c/83e30f2bf86ef7c38fbd476ed81a88522b620628" } ], "title": "USB: gadget: Fix the memory leak in raw_gadget driver", "x_generator": { "engine": "bippy-1.2.0" } } } }