CVE-2025-22104 Overview
CVE-2025-22104 is an out-of-bounds read vulnerability in the Linux kernel's ibmvnic network driver. The flaw exists in the driver's hex dump printing logic, which cast buffers to an 8-byte long and printed them using string formatters. When the buffer size was not a multiple of 8 bytes, the driver read beyond the allocated buffer boundary. KASAN (Kernel Address Sanitizer) reports confirmed the slab-out-of-bounds read in ibmvnic_login. The vulnerability affects IBM PowerVM virtual network interface deployments running Linux.
Critical Impact
A local low-privileged user can trigger an out-of-bounds read in kernel memory through the ibmvnic driver, potentially disclosing adjacent slab data or causing denial of service via KASAN-detected memory corruption.
Affected Products
- Linux Kernel (mainline versions prior to the fix commits)
- Linux distributions shipping the ibmvnic driver on IBM POWER platforms
- Stable kernel branches prior to backport commits ae6b1d6c1ace and d93a6caab5d7
Discovery Timeline
- 2025-04-16 - CVE-2025-22104 published to the National Vulnerability Database
- 2026-06-17 - Last updated in NVD database
Technical Details for CVE-2025-22104
Vulnerability Analysis
The vulnerability resides in the ibmvnic driver, which supports IBM Power Systems Virtual Network Interface Controllers. The driver contained diagnostic logging code that printed buffer contents as hex dumps. The implementation cast the buffer pointer to an unsigned 8-byte long and iterated with string formatters. This approach assumes that the buffer length is aligned to 8-byte boundaries.
When the driver logged the login response buffer, allocations frequently ended on non-aligned sizes. KASAN captured one such case with a 175-byte allocation at address c0000001331a9a00, where the read occurred 168 bytes into the region and extended past the 175-byte limit. The ibmvnic_login+0xacc/0xffc call path triggered the invalid read of 8 bytes beyond the allocation boundary.
The fix introduces a new helper that iterates over the buffer and calls the kernel's hex_dump_to_buffer function. This helper handles arbitrary buffer lengths safely and does not read past the allocation. The classification aligns with [CWE-125] Out-of-Bounds Read.
Root Cause
The root cause is unchecked pointer arithmetic in the driver's ad-hoc hex dump routine. The code assumed 8-byte alignment without validating buffer length. When the buffer size was not divisible by 8, the final iteration read beyond the allocated slab region.
Attack Vector
Exploitation requires local access with low privileges on a system running the vulnerable ibmvnic driver. An attacker with the ability to trigger driver operations that produce hex-dump logging, such as network interface initialization or login flows, can force the out-of-bounds read. The impact includes potential disclosure of adjacent kernel slab memory and kernel panics on systems configured with panic-on-KASAN.
No verified public exploitation code is available. The vulnerability was identified through KASAN instrumentation rather than an external proof-of-concept.
Detection Methods for CVE-2025-22104
Indicators of Compromise
- KASAN reports in kernel logs indicating slab-out-of-bounds reads originating from ibmvnic_login
- Kernel messages containing ibmvnic hex-dump output followed by BUG traces
- Unexpected kernel panics on IBM POWER systems using virtual network interfaces
Detection Strategies
- Enable KASAN on test kernels to surface out-of-bounds reads in the ibmvnic code path
- Collect and centralize dmesg output from POWER-based Linux hosts and alert on BUG: KASAN strings
- Inventory kernel versions across the fleet and flag hosts running builds without the fix commits ae6b1d6c1ace or d93a6caab5d7
Monitoring Recommendations
- Forward kernel logs to a centralized SIEM or data lake and create detections for ibmvnic combined with KASAN or slab-out-of-bounds
- Monitor for repeated crashes or reboots of virtualized network interfaces on IBM Power hardware
- Track kernel package versions through configuration management and compare against distribution security bulletins
How to Mitigate CVE-2025-22104
Immediate Actions Required
- Identify all Linux hosts running the ibmvnic driver, typically IBM Power Systems logical partitions with virtual network adapters
- Apply the vendor-provided kernel updates that include commits ae6b1d6c1ace3a2000394d83ec9f1028321e207 and d93a6caab5d7d9b5ce034d75b1e1e993338e3852
- Restrict local shell access on affected systems to reduce the population of users able to trigger the driver path
Patch Information
The upstream fix replaces the custom hex dump logic with a wrapper around the kernel's hex_dump_to_buffer helper. The patches are available in the stable kernel tree via Kernel Git Commit ae6b1d6c1ace and Kernel Git Commit d93a6caab5d7. Consume kernel updates through the distribution vendor's official channels once the fixes are backported.
Workarounds
- If patching is not immediately possible, reduce driver verbosity by ensuring debug-level ibmvnic logging is not enabled in production
- Limit local user access on affected POWER hosts and enforce least privilege for administrative accounts
- Consider migrating critical workloads to patched hosts while unpatched systems are scheduled for kernel updates
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

