# CVE-2025-21704: usb: cdc-acm: Check control transfer buffer size before access

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, NVD) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** Yes (see exploit references)
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.36% (percentile 22, 2026-11-26)
- **CWE:** CWE-787
- **Published:** 2025-02-22T09:43:37.377Z
- **Modified:** 2026-10-15T02:17:28.313Z

## Who should check

- Anyone running Linux \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< a4e1ae5c0533964170197e4fb4f33bc8c1db5cd2; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 90dd2f1b7342b9a671a5ea4160f408037b92b118; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 871619c2b78fdfe05afb4e8ba548678687beb812; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 7828e9363ac4d23b02419bf2a45b9f1d9fb35646; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 6abb510251e75f875797d8983a830e6731fa281c; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< f64079bef6a8a7823358c3f352ea29a617844636; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 383d516a0ebc8641372b521c8cb717f0f1834831; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< e563b01208f4d1f609bcab13333b6c0e24ce6a01
- Anyone running Linux 2.6.12

## Description

In the Linux kernel, the following vulnerability has been resolved:

usb: cdc-acm: Check control transfer buffer size before access

If the first fragment is shorter than struct usb\_cdc\_notification, we can't
calculate an expected\_size. Log an error and discard the notification
instead of reading lengths from memory outside the received data, which can
lead to memory corruption when the expected\_size decreases between
fragments, causing \`expected\_size - acm-\>nb\_index\` to wrap.

This issue has been present since the beginning of git history; however,
it only leads to memory corruption since commit ea2583529cd1
("cdc-acm: reassemble fragmented notifications").

A mitigating factor is that acm\_ctrl\_irq() can only execute after userspace
has opened /dev/ttyACM\*; but if ModemManager is running, ModemManager will
do that automatically depending on the USB device's vendor/product IDs and
its other interfaces.

## Affected and fixed versions

- Linux: \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< a4e1ae5c0533964170197e4fb4f33bc8c1db5cd2; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 90dd2f1b7342b9a671a5ea4160f408037b92b118; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 871619c2b78fdfe05afb4e8ba548678687beb812; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 7828e9363ac4d23b02419bf2a45b9f1d9fb35646; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 6abb510251e75f875797d8983a830e6731fa281c; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< f64079bef6a8a7823358c3f352ea29a617844636; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 383d516a0ebc8641372b521c8cb717f0f1834831; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< e563b01208f4d1f609bcab13333b6c0e24ce6a01 (cvelist)
- Linux: 2.6.12 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-21704. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-21704.md
Affected: Linux >= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, < a4e1ae5c0533964170197e4fb4f33bc8c1db5cd2; >= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, < 90dd2f1b7342b9a671a5ea4160f408037b92b118; >= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, < 871619c2b78fdfe05afb4e8ba548678687beb812; >= 1da177e4c3f41524e886b7f…
Fixed in: Linux 90dd2f1b7342b9a671a5ea4160f408037b92b118, Linux 871619c2b78fdfe05afb4e8ba548678687beb812, Linux 7828e9363ac4d23b02419bf2a45b9f1d9fb35646, Linux 6abb510251e75f875797d8983a830e6731fa281c, Linux 383d516a0ebc8641372b521c8cb717f0f1834831

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-21704 being exploited?

There is no confirmed exploitation: CVE-2025-21704 is not in the CISA Known Exploited Vulnerabilities catalog. Public exploit code or a proof of concept is available. EPSS estimates a 0.36% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-21704?

High: CVSS 7.8 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2025-21704?

Linux \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< a4e1ae5c0533964170197e4fb4f33bc8c1db5cd2; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 90dd2f1b7342b9a671a5ea4160f408037b92b118; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 871619c2b78fdfe05afb4e8ba548678687beb812; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 7828e9363ac4d23b02419bf2a45b9f1d9fb35646; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 6abb510251e75f875797d8983a830e6731fa281c; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< f64079bef6a8a7823358c3f352ea29a617844636; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< 383d516a0ebc8641372b521c8cb717f0f1834831; \>= 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2, \< e563b01208f4d1f609bcab13333b6c0e24ce6a01; Linux 2.6.12.

### Is there a fix for CVE-2025-21704?

Yes. Fixed in Linux 90dd2f1b7342b9a671a5ea4160f408037b92b118, Linux 871619c2b78fdfe05afb4e8ba548678687beb812, Linux 7828e9363ac4d23b02419bf2a45b9f1d9fb35646, Linux 6abb510251e75f875797d8983a830e6731fa281c, Linux 383d516a0ebc8641372b521c8cb717f0f1834831. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2025-21704?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/a4e1ae5c0533964170197e4fb4f33bc8c1db5cd2>
- patch: <https://git.kernel.org/stable/c/90dd2f1b7342b9a671a5ea4160f408037b92b118>
- patch: <https://git.kernel.org/stable/c/871619c2b78fdfe05afb4e8ba548678687beb812>
- patch: <https://git.kernel.org/stable/c/7828e9363ac4d23b02419bf2a45b9f1d9fb35646>
- patch: <https://git.kernel.org/stable/c/6abb510251e75f875797d8983a830e6731fa281c>
- patch: <https://git.kernel.org/stable/c/f64079bef6a8a7823358c3f352ea29a617844636>
- patch: <https://git.kernel.org/stable/c/383d516a0ebc8641372b521c8cb717f0f1834831>
- patch: <https://git.kernel.org/stable/c/e563b01208f4d1f609bcab13333b6c0e24ce6a01>
- exploit: <https://project-zero.issues.chromium.org/issues/395107243>
- other: <https://lists.debian.org/debian-lts-announce/2025/05/msg00030.html>
- other: <https://lists.debian.org/debian-lts-announce/2025/03/msg00028.html>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-265688.html>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-784472.html>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-21704>

HTML: <https://flawdb.com/CVE-2025-21704> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-21704>
