HIGH Introduced in 6.1
blk-mq CachedRequest UAF
CVE-2026-98820
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
01Description
In the Linux kernel, the following vulnerability has been resolved: blk-mq: set RQF_USE_SCHED when the operation is known The cached requests are allocated for one operation but can be handed out for another. A passthrough command has RQF_USE_SCHED cleared, so using those flags for a subsequent read/write bio will insert it into the scheduler without ->prepare_request() and frees it without ->finish_request(). For kyber, this leaks the domain token acquired at dispatch and stalls the queue. Don't set RQF_USE_SCHED based on the first operation the batch happened to be allocated for. Instead, set it after the request is claimed by an operation. Introduce a helper function, blk_mq_rq_late_init() for this, and absorb blk_mq_rq_time_init() since the two run together.
02KernelScan AI Analysis
Risk summary
A local attacker with access to a block device can trigger a scheduler state corruption by issuing a sequence of passthrough commands followed by regular read/write I/O. This leaks scheduler-internal resources (domain tokens in kyber) and stalls the request queue, causing a denial of service. The underlying use-after-free primitive may also allow privilege escalation.
Vulnerability analysis
The block multi-queue layer caches requests in batches before the actual I/O operation is known. When a batch is first allocated for a passthrough or flush command (which bypass the I/O scheduler), the RQF_USE_SCHED flag is cleared on those cached requests. If the same cached request is later reused for a regular read or write bio, it retains the cleared flag and enters the scheduler without the required prepare_request() callback, then exits without finish_request(). This leaves the scheduler's internal state inconsistent — for the kyber scheduler it leaks a domain token acquired at dispatch, permanently stalling the queue. The fix introduces blk_mq_rq_late_init() to initialize scheduler-related flags and callbacks only after the request is claimed for a specific operation, ensuring the flags match the actual I/O type. Any local user who can submit I/O to a block device (including container workloads with device access) can trigger this by mixing passthrough and regular I/O on a queue using a scheduler like kyber.
Lifecycle
03Fix Versions
| Branch | Introduced | Fixed in | Patch commit |
|---|---|---|---|
| 6.18 | 6.1 | 6.18.56 | 790730e4d95d |
| 7.2 | 6.1 | 7.2.10 | 2c47ebc27fa7 |
| mainline | 6.1 | 7.3 | ab6c756f28c7 |
04CIP Kernels
State of the newest release of each Civil Infrastructure Platform SLTS tree, from CIP's own fix records.
| CIP tree | State |
|---|---|
| cip/6.12 | Affected — no CIP fix yet (latest 6.12.114-cip34) |
| cip/6.1 | Affected — no CIP fix yet (latest 6.1.190-cip62) |
| cip/6.1-rt | Affected — no CIP fix yet (latest 6.1.189-cip61-rt32) |