KernelScan.io

CRITICAL Introduced in 4.14

inetpeer TreeTraversal Leak

CVE-2026-90110

CVSS 9.4 / 10.0 NVD

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

KernelScan AI3.6LOW

01

In the Linux kernel, the following vulnerability has been resolved: inetpeer: randomize RB-tree node comparison using SipHash The inetpeer rate limiting system stores peer entries in a Red-Black tree keyed deterministically on the remote IP address. Because tree lookups walk the RB-tree using standard lexicographical comparisons (inetpeer_addr_cmp), an off-path adversary can predict the exact topology of the tree and the sequence of nodes traversed during lookups (the gc_stack candidate list). By combining deterministic tree traversal with aggressive garbage collection (triggered when tree size exceeds inet_peer_threshold), an attacker can selectively force the eviction of targeted inet_peer nodes. When an evicted node is subsequently re-created upon receiving a new packet, its rate-limiting token bucket (rate_tokens, rate_last) is reset to full capacity. This creates a side-channel primitive allowing off-path attackers to bypass IP-keyed ICMP rate limits and infer open UDP ports (similar to SAD DNS style attacks). Mitigate this by randomizing the RB-tree node comparison logic using SipHash with a secret key (inetpeer_hash_key) initialized via net_get_random_once(). Nodes are ordered in the tree by SipHash(addr, key) rather than raw IP addresses. Because the secret key is unknown to external entities, the tree layout and lookup traversal paths are unpredictable to off-path adversaries, breaking the deterministic eviction gadget. Cache the computed 64-bit SipHash (hash) in struct inet_peer and compute the target hash (dhash) once at the beginning of inet_getpeer() to avoid recomputing SipHash at every step of the RB-tree walk.

02

Engine v0.6.0

Risk summary

An off-path network attacker can exploit the deterministic Red-Black tree layout of the inetpeer peer cache to selectively force eviction of targeted peer entries, resetting their ICMP rate-limiting token buckets. This side-channel allows bypassing IP-keyed ICMP rate limits and inferring open UDP ports, similar to SAD DNS attacks. Any networked Linux system receiving packets from untrusted sources is affected.

Affectednet/ipv4/inetpeer.c (inetpeer)

Vulnerability analysis

The inetpeer subsystem stores per-remote-IP peer entries in a Red-Black tree ordered by raw IP address, making the tree topology and garbage-collection eviction order fully predictable to an off-path attacker. By flooding the peer cache to exceed the configured threshold and trigger aggressive garbage collection, the attacker can selectively evict entries for specific target IPs; when a new packet recreates an evicted entry, its rate-limiting token bucket is reset to full capacity, enabling ICMP rate-limit bypass and open-port inference side channels. The fix randomizes tree ordering using a secret-keyed SipHash so that the tree layout and traversal paths are unpredictable to external entities, breaking the deterministic eviction gadget. The vulnerable code path is reached whenever the kernel processes incoming packets and performs peer lookups, requiring no privileges or user interaction from the attacker's perspective.

03

BranchIntroducedFixed inPatch commit
6.14.146.1.188b20e98f0bb66
6.64.146.6.1575f127e3cc964
6.124.146.12.110199fcf285e49
6.184.146.18.52857681f6835d
7.24.147.2.67109bb63667a
mainline4.147.3-rc12ee66e948717