In the Linux kernel, the following vulnerability has been resolved:
mpls: reload header after pskb_may_pull()
mpls_select_multipath() calls mpls_multipath_hash() to choose a nexthop
when an MPLS route has multiple nexthops. While walking the MPLS label
stack, the hash routine caches hdr for the current label. After finding
the bottom-of-stack label, it calls pskb_may_pull() before reading the
inner IP header.
If an skb is constructed with the inner IP header in nonlinear data and
insufficient tailroom in the linear head, pskb_may_pull() calls
pskb_expand_head() to replace the skb head and free the old one. This
leaves hdr pointing to freed memory. The IPv6 path can invalidate hdr
again when it performs a second pull for the larger header.
The issue was found through static analysis. A reproducer sending a legal
Geneve packet through a bareudp/MPLS multipath setup triggered the same
KASAN report in 2 of 2 unpatched runs:
BUG: KASAN: slab-use-after-free in mpls_select_multipath
Read of size 1 at addr ffff88800ecc6e20 by task ksoftirqd/1/23
Call Trace:
mpls_select_multipath
mpls_forward
__netif_receive_skb_list_core
netif_receive_skb_list_internal
napi_complete_done
gro_cell_poll
__napi_poll
net_rx_action
Freed by task 23:
kfree
pskb_expand_head
__pskb_pull_tail
mpls_select_multipath
Reload hdr from the current skb head after each successful pull before
deriving the inner IPv4 or IPv6 header pointer.
CVSS Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS Score: 9.8
AV:N - mpls_forward() is the ETH_P_MPLS_UC packet_type receive handler; remote MPLS-in-IP (IPPROTO_MPLS), MPLS-over-UDP/bareudp, Geneve, and IPIP/SIT/ip6 tunnels deliver inner MPLS into this path without local access, matching the Geneve/bareudp KASAN reproducer.
AC:L - An attacker sending MPLS or tunneled overlay frames fully controls the label stack, BOS bit, and skb layout; GRO/tunnel decap yields nonlinear skbs so pskb_may_pull() reallocates skb->head, and the unpatched Geneve reproducer hit the UAF in 2 of 2 runs with no victim-timed race.
PR:N - Exploitation needs only unauthenticated packets that hit an already configured MPLS-enabled interface and multipath label route; mpls_forward() performs no credential check, and enabling MPLS input or tunnels is victim deployment rather than an attacker privilege.
UI:N - The use-after-free runs in softirq receive processing (gro_cell_poll / netif_receive_skb_list) as soon as the crafted frame is accepted; no local user or administrator action is required beyond normal forwarding.
S:U - The stale MPLS header pointer is a heap use-after-free inside the same host kernel MPLS forwarding path; impact stays within that kernel security authority and does not cross a VM, IOMMU, or other boundary.
C:H - After pskb_expand_head() frees the old skb head, mpls_multipath_hash() reads the inner IPv4/IPv6 header through the stale hdr pointer, a slab use-after-free that can disclose freed kmalloc contents and is scored as high-impact kernel information disclosure.
I:H - The immediate stale access is a header read used for ECMP hashing, but it remains a kernel slab use-after-free of skb->head; attacker-controlled reclaim of the freed kmalloc object is a well-established path to heap corruption and control-flow hijacking.
A:H - KASAN confirmed a slab-use-after-free in mpls_select_multipath() on the forwarding path; dereferencing the freed skb head can oops or panic the kernel, and UAFs remain a high-impact denial of service even without full exploitation.
| Attack Vector |
Network |
Scope |
Unchanged |
| Attack Complexity |
Low |
Confidentiality Impact |
High |
| Privileges Required |
None |
Integrity Impact |
High |
| User Interaction |
None |
Availability Impact |
High |
AV:N - mpls_forward() is the ETH_P_MPLS_UC packet_type receive handler; remote MPLS-in-IP (IPPROTO_MPLS), MPLS-over-UDP/bareudp, Geneve, and IPIP/SIT/ip6 tunnels deliver inner MPLS into this path without local access, matching the Geneve/bareudp KASAN reproducer.
AC:L - An attacker sending MPLS or tunneled overlay frames fully controls the label stack, BOS bit, and skb layout; GRO/tunnel decap yields nonlinear skbs so pskb_may_pull() reallocates skb->head, and the unpatched Geneve reproducer hit the UAF in 2 of 2 runs with no victim-timed race.
PR:N - Exploitation needs only unauthenticated packets that hit an already configured MPLS-enabled interface and multipath label route; mpls_forward() performs no credential check, and enabling MPLS input or tunnels is victim deployment rather than an attacker privilege.
UI:N - The use-after-free runs in softirq receive processing (gro_cell_poll / netif_receive_skb_list) as soon as the crafted frame is accepted; no local user or administrator action is required beyond normal forwarding.
S:U - The stale MPLS header pointer is a heap use-after-free inside the same host kernel MPLS forwarding path; impact stays within that kernel security authority and does not cross a VM, IOMMU, or other boundary.
C:H - After pskb_expand_head() frees the old skb head, mpls_multipath_hash() reads the inner IPv4/IPv6 header through the stale hdr pointer, a slab use-after-free that can disclose freed kmalloc contents and is scored as high-impact kernel information disclosure.
I:H - The immediate stale access is a header read used for ECMP hashing, but it remains a kernel slab use-after-free of skb->head; attacker-controlled reclaim of the freed kmalloc object is a well-established path to heap corruption and control-flow hijacking.
A:H - KASAN confirmed a slab-use-after-free in mpls_select_multipath() on the forwarding path; dereferencing the freed skb head can oops or panic the kernel, and UAFs remain a high-impact denial of service even without full exploitation.
CVSS 3.1