Linux: tcp: reject net_iov in zerocopy receive mapping hints
What fixes it
- 563d3564513496b9ce3b3ba7a5154427554d0f06LinuxCVE List
- 1c7463ac0e99cc91c4eecc1b69a740ef1a619932LinuxCVE List
- 3aa6f536a95eb0617c313ae2eb76fdfa85331f85LinuxCVE List
- 8b1f0af1fd5fd113432233ed8a3862ee7c30a84fLinuxCVE List
A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.
Description
In the Linux kernel, the following vulnerability has been resolved:
tcp: reject net_iov in zerocopy receive mapping hints
After copying a readable prefix, receive_fallback_to_copy() asks tcp_zerocopy_set_hint_for_skb() where page mapping can resume. If the next skb is unreadable, find_next_mappable_frag() passes its net_iov fragment to can_map_frag().
skb_frag_page() returns NULL for a net_iov, but can_map_frag() dereferences it in PageCompound(). A v7.2 KASAN run on a connected TCP socket with 64 readable bytes followed by a 4096-byte NET_IOV_DMABUF fragment reported:
BUG: KASAN: null-ptr-deref in can_map_frag tcp_zerocopy_receive -> can_map_frag Kernel panic - not syncing: KASAN: panic_on_warn set
The diagnostic inserted the net_iov directly because the test host has no devmem-capable NIC. Hardware end-to-end reachability remains untested and requires CONFIG_NET_DEVMEM plus a supported DMA-buf-bound RX queue.
Reject all net_iov fragments before skb_frag_page(). This covers both DMABUF and IOURING net_iov types while leaving page-backed checks unchanged. With the guard, the same queue copied the readable prefix, returned a 4096-byte skip hint, and completed without a fault.
Text from CVE List
Affected versions 10
- Linuxaffected: 9f6b619edf2e85746f261b42ae8f818a59d126f7 before 563d3564513496b9ce3b3ba7a5154427554d0f06CVE List
- Linuxaffected: 9f6b619edf2e85746f261b42ae8f818a59d126f7 before 1c7463ac0e99cc91c4eecc1b69a740ef1a619932CVE List
- Linuxaffected: 9f6b619edf2e85746f261b42ae8f818a59d126f7 before 3aa6f536a95eb0617c313ae2eb76fdfa85331f85CVE List
- Linuxaffected: 9f6b619edf2e85746f261b42ae8f818a59d126f7 before 8b1f0af1fd5fd113432233ed8a3862ee7c30a84fCVE List
- Linuxaffected: 6.12CVE List
- Linuxunaffected: all versions before 6.12CVE List
- Linuxunaffected: 6.12.113 through 6.12.*CVE List
- Linuxunaffected: 6.18.57 through 6.18.*CVE List
- Linuxunaffected: 7.2.11 through 7.2.*CVE List
- Linuxunaffected: 7.3CVE List
References 4
- git.kernel.org/stable/c/563d3564513496b9ce3b3ba7a5154427554d0f06Referencevia CVE List
- git.kernel.org/stable/c/1c7463ac0e99cc91c4eecc1b69a740ef1a619932Referencevia CVE List
- git.kernel.org/stable/c/3aa6f536a95eb0617c313ae2eb76fdfa85331f85Referencevia CVE List
- git.kernel.org/stable/c/8b1f0af1fd5fd113432233ed8a3862ee7c30a84fReferencevia CVE List