iommufd: Set upper bounds on cache invalidation entry_num and entry_len
No exploitation in the wild has been reported. EPSS puts the chance of exploitation in the next 30 days at 0%. Fixed in Kernel 6.18.39, Kernel 7.1.4, Kernel 6.12.96 and 4 more.
In the Linux kernel, the following vulnerability has been resolved: iommufd: Set upper bounds on cache invalidation entry_num and entry_len iommufd_hwpt_invalidate() takes a user-controlled entry_num and entry_len, each bounded only by U32_MAX. An entry_len beyond the kernel's struct size makes the copy helper verify the extra bytes are zero, scanning that excess in one uninterruptible pass; a multi-gigabyte value over zeroed user memory trips the soft-lockup watchdog. A large entry_num is the other half, driving the backend invalidation loop with no reschedule. The VT-d nested handler, for one, copies each entry and flushes caches per iteration, pinning the CPU on a non-preemptible kernel. Cap both in the ioctl. entry_len is held under PAGE_SIZE, above any request struct, and entry_num under 1 << 19, the order of a hardware invalidation queue and well beyond any real batch, bounding the per-call loop length.
Affected
Vendors, products and packages with version ranges
| Vendor | Product | Versions | Fixed |
|---|---|---|---|
| Linux | Kernel | >=6.13 <6.18.39, >=6.19 <7.1.4, >=6.8 <6.12.96, >=8c6eabae3807e048b9f17733af5e20500fbf858c <32ca4aed2a66205b072fcfecabe220289a8149ff, >=8c6eabae3807e048b9f17733af5e20500fbf858c <4d70986002f2f3eaaed89124fb2522bded38b016, >=8c6eabae3807e048b9f17733af5e20500fbf858c <d2bd041e0efaf7d81789779b135279d18b33d6d5, =6.8, >=8c6eabae3807e048b9f17733af5e20500fbf858c <2c6381d90898089287e0a358f06f89f6b4b389f2 | 6.18.39, 7.1.4, 6.12.96, 32ca4aed2a66205b072fcfecabe220289a8149ff, 4d70986002f2f3eaaed89124fb2522bded38b016, d2bd041e0efaf7d81789779b135279d18b33d6d5, 2c6381d90898089287e0a358f06f89f6b4b389f2 |
| linux-kernel: Kernel | >=6.13.0 <6.18.39, >=6.19.0 <7.1.4, >=6.8.0 <6.12.96 | 6.18.39, 7.1.4, 6.12.96 |
Timeline
Every event on this vulnerability
Related
Other vulnerabilities in Kernel, strongest first
Embed
A live severity badge for an advisory, README or ticket