MOKSHA-2026-0022: Real-Time I/O Class Abuse via VBD.qos_algorithm_params - Cross-VM Starvation

Advisory IDMOKSHA-2026-0022
Semantic IDBQP-1
Published2026-04-24
CVSS 3.17.5 High
CVSS 3.1 VectorAV:N/AC:L/PR:L/UI:N/S:C/C:N/I:N/A:H
CVSS 4.08.3 High
CVSS 4.0 VectorAV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:H/VA:N/SC:N/SI:H/SA:N
XAPI ObjectVBD
XAPI Fieldqos_algorithm_params:sched
Entry Rolevm-admin
ResearcherJakob Wolffhechel, Moksha

Affected Products

VendorProductVersions
Citrix / Cloud Software GroupXenServer / Citrix Hypervisorall versions (shared XAPI codebase)
VatesXCP-ng8.3.0

Summary

A user with the vm-admin role in XAPI-based hypervisors (XenServer, XCP-ng) can set the real-time I/O scheduling class on their VM's virtual block devices by writing sched=rt and class=highest to VBD.qos_algorithm_params. xenopsd invokes ionice -c1 -n0 on the VBD kernel threads, granting them strict priority over all best-effort and idle I/O across the host. This starves I/O for every other VM on the same host. The change takes effect immediately without VBD replug, requires no shell access, and produces no security alert.

Vulnerability Description

VBD.qos_algorithm_params is a Map(String, String) field writable by vm-admin. When VBD.qos_algorithm_type is set to ionice, the sched and class keys are parsed by XAPI into a qos_scheduler struct and forwarded to xenopsd.

The code path:

  1. vm-admin sets VBD.qos_algorithm_type = "ionice" and VBD.qos_algorithm_params = {sched: "rt", class: "highest"}
  2. XAPI parses the values at xapi_xenops.ml:595-600 into Ionice.RealTime(0)
  3. xenopsd invokes ionice -c1 -n0 -p<kthread_pid> on all VBD kernel threads
  4. The Linux kernel grants these threads strict real-time I/O priority
  5. All other VMs' VBD threads (in best-effort or idle class) are starved

The field has zero per-key RBAC. No shell injection is possible (xenopsd uses execve), but the real-time I/O scheduling class provides strict priority that starves other tenants' I/O.

Hot Apply

Changes to qos_algorithm_params take effect immediately. XAPI applies the new ionice settings without requiring a VBD unplug/replug cycle or VM restart.

Root Causes

  1. Missing RBAC protection. VBD.qos_algorithm_params has zero map_keys_roles entries. The sched key is writable by vm-admin.

  2. Missing value validation. The real-time scheduling class (sched=rt) is accepted without any role check. No policy limits which scheduling classes a vm-admin can request.

  3. No per-host RT I/O budget. There is no mechanism to limit the number of VBDs in the real-time I/O class per host. A single vm-admin can consume the entire RT I/O budget.

  4. Insufficient logging. No security alert is generated when a VBD is assigned the real-time scheduling class.

Affected Systems

Directly Affected

Indirectly Affected

Exploitation Scenarios

Scenario Impact Pre-conditions Status
Cross-VM I/O starvation All other VMs on the host experience severe I/O latency vm-admin credential, ionice QoS type Source-traced
Shared storage amplification RT scheduling starves other hosts' I/O threads competing for shared LUNs Shared storage (iSCSI, NFS, FC) Modeled
Bulk RT assignment via BOC-1 Root access enables setting RT class on all VBDs in the pool simultaneously BOC-1 available Modeled (amplification chain)

Detection

Remediation

Short-Term Mitigations

Long-Term Fix

Restrict real-time scheduling. Add map_keys_roles for the sched key or validate that sched=rt requires pool-admin role.

Range-validate class values. Accept only integers in the range 0-7.

Per-host RT I/O budget. Implement a limit on the number of VBDs that can use the real-time scheduling class per host.

Upstream patches exist. They are held privately pending coordinated disclosure.

Disclosure

Disclosure:

References

Credits

Discovered and reported by Jakob Wolffhechel, Moksha.

Jakob Wolffhechel · Moksha · Copenhagen
jakob@wolffhechel.dk · +45 3170 7337
Published 2026-04-24 08:00 CEST · cna.moksha.dk · shittrix.moksha.dk