# CVE-2021-47475: comedi: vmk80xx: fix transfer-buffer overflows

> 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:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.35% (percentile 21, 2026-11-26)
- **CWE:** CWE-787
- **Published:** 2024-05-22T08:19:29.423Z
- **Modified:** 2026-06-17T04:17:33.480Z

## Who should check

- Anyone running Linux \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 5229159f1d052821007aff1a1beb7873eacf1a9f; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< ec85bcff4ed09260243d8f39faba99e1041718ba; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 7a2021b896de1ad559d33b5c5cdd20b982242088; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 199acd8c110e3ae62833c24f632b0bb1c9f012a9; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 33d7a470730dfe7c9bfc8da84575cf2cedd60d00; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 278484ae93297b1bb1ce755f9d3b6d95a48c7d47; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 06ac746d57e6d32b062e220415c607b7e2e0fa50; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< a23461c47482fc232ffc9b819539d1f837adf2b1
- Anyone running Linux 2.6.31

## Description

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

comedi: vmk80xx: fix transfer-buffer overflows

The driver uses endpoint-sized USB transfer buffers but up until
recently had no sanity checks on the sizes.

Commit e1f13c879a7c ("staging: comedi: check validity of wMaxPacketSize
of usb endpoints found") inadvertently fixed NULL-pointer dereferences
when accessing the transfer buffers in case a malicious device has a
zero wMaxPacketSize.

Make sure to allocate buffers large enough to handle also the other
accesses that are done without a size check (e.g. byte 18 in
vmk80xx\_cnt\_insn\_read() for the VMK8061\_MODEL) to avoid writing beyond
the buffers, for example, when doing descriptor fuzzing.

The original driver was for a low-speed device with 8-byte buffers.
Support was later added for a device that uses bulk transfers and is
presumably a full-speed device with a maximum 64-byte wMaxPacketSize.

## Affected and fixed versions

- Linux: \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 5229159f1d052821007aff1a1beb7873eacf1a9f; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< ec85bcff4ed09260243d8f39faba99e1041718ba; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 7a2021b896de1ad559d33b5c5cdd20b982242088; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 199acd8c110e3ae62833c24f632b0bb1c9f012a9; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 33d7a470730dfe7c9bfc8da84575cf2cedd60d00; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 278484ae93297b1bb1ce755f9d3b6d95a48c7d47; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 06ac746d57e6d32b062e220415c607b7e2e0fa50; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< a23461c47482fc232ffc9b819539d1f837adf2b1 (cvelist)
- Linux: 2.6.31 (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-2021-47475. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2021-47475.md
Affected: Linux >= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, < 5229159f1d052821007aff1a1beb7873eacf1a9f; >= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, < ec85bcff4ed09260243d8f39faba99e1041718ba; >= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, < 40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7; >= 985cafccbf9b7f862aa1c5e…
Fixed in: Linux 5229159f1d052821007aff1a1beb7873eacf1a9f, Linux 40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7, Linux 7a2021b896de1ad559d33b5c5cdd20b982242088, Linux 199acd8c110e3ae62833c24f632b0bb1c9f012a9, Linux 33d7a470730dfe7c9bfc8da84575cf2cedd60d00, Linux 278484ae93297b1bb1ce755f9d3b6d95a48c7d47, Linux 06ac7…

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-2021-47475 being exploited?

There is no confirmed exploitation: CVE-2021-47475 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.35% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2021-47475?

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

### Which versions are affected by CVE-2021-47475?

Linux \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 5229159f1d052821007aff1a1beb7873eacf1a9f; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< ec85bcff4ed09260243d8f39faba99e1041718ba; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 7a2021b896de1ad559d33b5c5cdd20b982242088; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 199acd8c110e3ae62833c24f632b0bb1c9f012a9; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 33d7a470730dfe7c9bfc8da84575cf2cedd60d00; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 278484ae93297b1bb1ce755f9d3b6d95a48c7d47; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< 06ac746d57e6d32b062e220415c607b7e2e0fa50; \>= 985cafccbf9b7f862aa1c5ee566801e18b5161fb, \< a23461c47482fc232ffc9b819539d1f837adf2b1; Linux 2.6.31.

### Is there a fix for CVE-2021-47475?

Yes. Fixed in Linux 5229159f1d052821007aff1a1beb7873eacf1a9f, Linux 40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7, Linux 7a2021b896de1ad559d33b5c5cdd20b982242088, Linux 199acd8c110e3ae62833c24f632b0bb1c9f012a9, Linux 33d7a470730dfe7c9bfc8da84575cf2cedd60d00, Linux 278484ae93297b1bb1ce755f9d3b6d95a48c7d47, Linux 06ac746d57e6d32b062e220415c607b7e2e0fa50. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2021-47475?

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/5229159f1d052821007aff1a1beb7873eacf1a9f>
- patch: <https://git.kernel.org/stable/c/ec85bcff4ed09260243d8f39faba99e1041718ba>
- patch: <https://git.kernel.org/stable/c/40d2a7e278e2e7c0a5fd7e997e7eb63945bf93f7>
- patch: <https://git.kernel.org/stable/c/7a2021b896de1ad559d33b5c5cdd20b982242088>
- patch: <https://git.kernel.org/stable/c/199acd8c110e3ae62833c24f632b0bb1c9f012a9>
- patch: <https://git.kernel.org/stable/c/33d7a470730dfe7c9bfc8da84575cf2cedd60d00>
- patch: <https://git.kernel.org/stable/c/278484ae93297b1bb1ce755f9d3b6d95a48c7d47>
- patch: <https://git.kernel.org/stable/c/06ac746d57e6d32b062e220415c607b7e2e0fa50>
- patch: <https://git.kernel.org/stable/c/a23461c47482fc232ffc9b819539d1f837adf2b1>

## 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-2021-47475>

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