# CVE-2021-32846: Moby HyperKit uninitialized memory use in virtio-sock pci_vtsock_proc_tx

- Severity: High 7.7 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.33%, higher than 27% of CVEs (2026-12-01)
- Published: 2023-02-17T00:00:00.000Z
- Modified: 2026-06-17T03:53:44.990Z
- Weaknesses: CWE-754, CWE-908
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

HyperKit is a toolkit for embedding hypervisor capabilities in an application. In versions 0.20210107, function `pci_vtsock_proc_tx` in `virtio-sock` can lead to to uninitialized memory use. In this situation, there is a check for the return value to be less or equal to `VTSOCK_MAXSEGS`, but that check is not sufficient because the function can return `-1` if it finds an error it cannot recover from. Moreover, the negative return value will be used by `iovec_pull` in a while condition that can further lead to more corruption because the function is not designed to handle a negative `iov_len`. This issue may lead to a guest crashing the host causing a denial of service and, under certain circumstance, memory corruption. This issue is fixed in commit af5eba2360a7351c08dfd9767d9be863a50ebaba.

(As written by CVE List.)

## Affected

- moby hyperkit: from 0.20210107 up to 0.20210107
- mobyproject hyperkit: up to 0.20210107

## Every score

- GitHub_M: CVSS:3.1 7.7 High `CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://securitylab.github.com/advisories/GHSL-2021-054_057-moby-hyperkit/> (third-party-advisory)
- <https://github.com/moby/hyperkit/pull/313> (patch)
- <https://github.com/moby/hyperkit/commit/af5eba2360a7351c08dfd9767d9be863a50ebaba> (patch)

## Sources

- CVE List: [CVE-2021-32846](https://www.cve.org/CVERecord?id=CVE-2021-32846), CVE Terms of Use, modified 2025-03-10
- NVD: [CVE-2021-32846](https://nvd.nist.gov/vuln/detail/CVE-2021-32846), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2021-32846 · Whole record: https://cve.day/CVE-2021-32846.json · Rebuilt by cve.day 2026-11-25T22:58:08.226Z
