KernelScan.io

HIGH Introduced in 2.6.26

qeth QueryIoctl Overflow

CVE-2026-80584

CVSS 8.4 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

KernelScan AI6.3MEDIUM

01

In the Linux kernel, the following vulnerability has been resolved: s390/qeth: validate user buffer length in SNMP and ARP query ioctls qeth_snmp_command() and qeth_l3_arp_query() allocate a buffer sized by a user-supplied length (udata_len) without checking a lower bound, then set udata_offset to a fixed non-zero value and pass both to a reply callback. The callback bounds-checks the copy with if ((udata_len - udata_offset) < len) Both fields are u32, so a udata_len smaller than udata_offset makes the subtraction wrap and the check pass, and the following memcpy() writes past the allocation. A udata_len of 0 also yields ZERO_SIZE_PTR from kzalloc(), which the existing NULL check does not catch. Reject buffers smaller than udata_offset before allocating, so the callback subtraction can no longer underflow.

02

Engine v0.6.0

Risk summary

A local attacker with CAP_NET_ADMIN on an s390 system with qeth network hardware can trigger a heap buffer overflow via SNMP or ARP query ioctls by supplying a buffer length smaller than a fixed internal offset. This can corrupt kernel heap memory, potentially leading to privilege escalation or system crash. The vulnerability requires s390-specific hardware and is not network-reachable.

Affecteddrivers/s390/net/qeth_core_main.c, drivers/s390/net/qeth_l3_main.c (s390 qeth network driver)

Vulnerability analysis

The qeth network driver's SNMP and ARP query ioctl handlers accept a user-supplied buffer length, allocate a buffer of that size, and later pass the length along with a fixed non-zero offset to a callback. The callback validates the copy size by subtracting the offset from the length using unsigned 32-bit arithmetic; when the user-supplied length is smaller than the offset, the subtraction wraps to a very large value, the bounds check passes, and a subsequent memory copy writes far past the end of the allocated buffer. A zero-length request also produces a special small-allocation pointer that bypasses the existing NULL check. The fix rejects any buffer length smaller than the fixed offset before allocating, so the unsigned subtraction in the callback can no longer underflow. The vulnerable path is reachable locally by any process holding CAP_NET_ADMIN in the init namespace on an s390 system with a qeth network device configured.

03

BranchIntroducedFixed inPatch commit
5.152.6.265.15.21746443eaddebd
5.102.6.265.10.2669d00eeb2d27f
6.122.6.266.12.1053083818e67bc
7.12.6.267.1.1075fb3151513d
6.182.6.266.18.46a30836477479
6.62.6.266.6.153cc423f4105fe
mainline2.6.267.2d141f087b1af
6.12.6.266.1.18491935843f939
cip/5.102.6.265.10.268-cip779d00eeb2d27f
cip/5.10-rt2.6.265.10.268-cip77-rt349d00eeb2d27f
cip/6.12.6.266.1.187-cip6091935843f939
cip/6.122.6.266.12.108-cip313083818e67bc