Unrated severityNVD Advisory· Published May 11, 2020· Updated Sep 17, 2024
Buffer Overflow in USB DFU requested length
CVE-2020-10019
Description
USB DFU has a potential buffer overflow where the requested length (wLength) is not checked against the buffer size. This could be used by a malicious USB host to exploit the buffer overflow. See NCC-ZEP-002 This issue affects: zephyrproject-rtos zephyr version 1.14.1 and later versions. version 2.1.0 and later versions.
Affected products
1- Range: 1.14.1
Patches
3afb307d3ff99usb: dfu: check requested length (wLength) during DFU_UPLOAD
1 file changed · +9 −0
subsys/usb/class/usb_dfu.c+9 −0 modified@@ -515,6 +515,15 @@ static int dfu_class_handle_req(struct usb_setup_packet *pSetup, len = pSetup->wLength; } + if (len > USB_DFU_MAX_XFER_SIZE) { + /* + * The host could requests more data as stated + * in wTransferSize. Limit upload length to the + * size of the request-buffer. + */ + len = USB_DFU_MAX_XFER_SIZE; + } + if (len) { const struct flash_area *fa;
8289dc75dda5usb: dfu: check requested length (wLength) during DFU_UPLOAD
1 file changed · +9 −0
subsys/usb/class/usb_dfu.c+9 −0 modified@@ -509,6 +509,15 @@ static int dfu_class_handle_req(struct usb_setup_packet *pSetup, len = pSetup->wLength; } + if (len > USB_DFU_MAX_XFER_SIZE) { + /* + * The host could requests more data as stated + * in wTransferSize. Limit upload length to the + * size of the request-buffer. + */ + len = USB_DFU_MAX_XFER_SIZE; + } + if (len) { const struct flash_area *fa;
105849cf38bfusb: dfu: check requested length (wLength) during DFU_UPLOAD
1 file changed · +9 −0
subsys/usb/class/usb_dfu.c+9 −0 modified@@ -509,6 +509,15 @@ static int dfu_class_handle_req(struct usb_setup_packet *pSetup, len = pSetup->wLength; } + if (len > USB_DFU_MAX_XFER_SIZE) { + /* + * The host could requests more data as stated + * in wTransferSize. Limit upload length to the + * size of the request-buffer. + */ + len = USB_DFU_MAX_XFER_SIZE; + } + if (len) { const struct flash_area *fa;
Vulnerability mechanics
Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
5- docs.zephyrproject.org/latest/security/vulnerabilities.htmlmitrex_refsource_MISC
- github.com/zephyrproject-rtos/zephyr/pull/23190mitrex_refsource_MISC
- github.com/zephyrproject-rtos/zephyr/pull/23457mitrex_refsource_MISC
- github.com/zephyrproject-rtos/zephyr/pull/23460mitrex_refsource_MISC
- zephyrprojectsec.atlassian.net/browse/ZEPSEC-25mitrex_refsource_MISC
News mentions
0No linked articles in our index yet.