# CVE-2026-99686: vhost: fix used ring index wrap in vhost_add_used_n_in_order

- Severity: High 7.8 (CVSS:3.1, scored by Linux) `CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:C/C:H/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.15%, higher than 4% of CVEs (2026-12-02)
- Published: 2026-11-20T05:50:31.888Z
- Modified: 2026-11-22T11:17:06.663Z
- Assigned by: Linux

## Description

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

vhost: fix used ring index wrap in vhost_add_used_n_in_order

vhost_add_used_n_in_order() advances start by nheads[i] but wraps it
with a single subtraction.  If start + nheads[i] >= 2 * vq->num, start
can remain outside the ring.

With used-ring logging enabled, start > vq->num makes (vq->num - start)
underflow.  log_write() then sets bits beyond the dirty-log bitmap,
potentially corrupting adjacent userspace memory.  This is reachable on
the vhost-net TX path with VIRTIO_F_IN_ORDER: done_idx can reach
VHOST_NET_BATCH (64), triggering the issue with a 32-entry ring.

Wrap start with a mask to keep it within the ring.  VHOST_SET_VRING_NUM
enforces a nonzero power-of-two ring size, allowing start to be wrapped
using & (vq->num - 1).

(As written by CVE List.)

## Affected

- Linux Linux: from 67a873df0c410915275f735fedb401b9637d6faf before ebdc350cfb1740b6411420482e58a35cc4761628; from 67a873df0c410915275f735fedb401b9637d6faf before 308e148cf771ed36ad8cd7ef0e9bee2f7ec478d0; from 67a873df0c410915275f735fedb401b9637d6faf before e244725e86be02cd85cb878b3ed8570eba2e4be1; 6.17 (not affected: before 6.17; from 6.18.64 up to 6.18.*; from 7.3.5 up to 7.3.*; from 7.4-rc2 up to *)

## References

- <https://git.kernel.org/stable/c/ebdc350cfb1740b6411420482e58a35cc4761628>
- <https://git.kernel.org/stable/c/308e148cf771ed36ad8cd7ef0e9bee2f7ec478d0>
- <https://git.kernel.org/stable/c/e244725e86be02cd85cb878b3ed8570eba2e4be1>

## Sources

- CVE List: [CVE-2026-99686](https://www.cve.org/CVERecord?id=CVE-2026-99686), CVE Terms of Use, modified 2026-11-22
- NVD: [CVE-2026-99686](https://nvd.nist.gov/vuln/detail/CVE-2026-99686), Public domain, modified 2026-11-22

---

Page: https://cve.day/CVE-2026-99686 · Whole record: https://cve.day/CVE-2026-99686.json · Rebuilt by cve.day 2026-11-25T22:59:52.307Z
