Overview
About vulnerability
In the Linux kernel, the following vulnerability has been resolved:
net: skbuff: propagate shared-frag marker through frag-transfer helpers
Two frag-transfer helpers (__pskb_copy_fclone() and skb_shift()) fail to propagate the SKBFL_SHARED_FRAG bit in skb_shinfo()->flags when moving frags from source to destination. _pskb_copy_fclone() defers the rest of the shinfo metadata to skb_copy_header() after copying frag descriptors, but that helper only carries over gso{size,segs, type} and never touches skb_shinfo()->flags; skb_shift() moves frag descriptors directly and leaves flags untouched. As a result, the destination skb keeps a reference to the same externally-owned or page-cache-backed pages while reporting skb_has_shared_frag() as false.
The mismatch is harmful in any in-place writer that uses
skb_has_shared_frag() to decide whether shared pages must be detoured
through skb_cow_data(). ESP input is one such writer (esp4.c,
esp6.c), and a single nft ‘dup to
Set SKBFL_SHARED_FRAG on the destination whenever frag descriptors were actually moved from the source. skb_copy() and skb_copy_expand() share skb_copy_header() too but linearize all paged data into freshly allocated head storage and emerge with nr_frags == 0, so skb_has_shared_frag() returns false on its own; they need no change.
The same omission exists in skb_gro_receive() and skb_gro_receive_list(). The former moves the incoming skb’s frag descriptors into the accumulator’s last sub-skb via two paths (a direct frag-move loop and the head_frag + memcpy path); the latter chains the incoming skb whole onto p’s frag_list. Downstream skb_segment() reads only skb_shinfo(p)->flags, and skb_segment_list() reuses each sub-skb’s shinfo as the nskb – both p and lp must carry the marker.
The same omission also exists in tcp_clone_payload(), which builds an MTU probe skb by moving frag descriptors from skbs on sk_write_queue into a freshly allocated nskb. The helper falls into the same family and warrants the same fix for consistency; no TCP TX-side in-place writer is currently known to reach a user page through this gap, but a future consumer depending on the marker would regress silently.
The same omission exists in skb_segment(): the per-iteration flag merge takes only head_skb’s flag, and the inner switch that rebinds frag_skb to list_skb on head_skb-frags exhaustion does not fold the new frag_skb’s flag into nskb. Fold frag_skb’s flag at both sites so segments drawing frags from frag_list members carry the marker.
Details
- Affected product:
- AlmaLinux 9.2 ESU , CentOS 8.4 ELS , CentOS 8.5 ELS , CentOS Stream 8 ELS , Oracle Linux 7 ELS , TuxCare 9.6 ESU , Ubuntu 16.04 ELS , Ubuntu 18.04 ELS , Ubuntu 20.04 ELS
- Affected packages:
- kernel @ 4.18.0 (+13 more)
Fixes
KernelCare state
Live-patch status from KernelCare for each operating system.
| Operating system | Status | Covered kernels |
|---|---|---|
| Amazon Linux 2 | Released |
121 kernels
|
| Amazon Linux 2023 | Released |
56 kernels
|
| Debian 11 | Planned | — |
| Debian 11 cloud | Planned | — |
| Debian 12 | Released |
39 kernels
|
| Debian 13 | Released |
8 kernels
|
| Oracle Linux 7 UEK 6 | Ready For Release | — |
| Oracle Linux 8 UEK 6 | Ready For Release | — |
| Proxmox VE 7 5.15 | Released |
47 kernels
|
| RHEL 10 | Planned | — |
| RHEL 8 | Planned | — |
| RHEL8 EUS 8.6 | Planned | — |
| RHEL 9 | Planned | — |
| Ubuntu 18.04 | Planned | — |
| Ubuntu 18.04 Azure | Planned | — |
| Ubuntu 18.04 GCP | Planned | — |
| Ubuntu 20.04 HWE AWS | Released |
57 kernels
|
| Ubuntu 20.04 HWE Azure | Released |
40 kernels
|
| Ubuntu 22.04 | Released |
95 kernels
|
| Ubuntu 22.04 AWS | Released |
86 kernels
|
| Ubuntu 22.04 Azure | Released |
76 kernels
|
| Ubuntu 22.04 HWE Noble AWS | Planned | — |
| Ubuntu 24.04 | Released |
44 kernels
|
| Ubuntu 24.04 AWS | Planned | — |