CVE-2026-99030: net: skbuff: don't leave stale bytes in skb_copy_and_csum_bits()
In the Linux kernel, the following vulnerability has been resolved:
net: skbuff: don't leave stale bytes in skbcopyandcsumbits()
When skbcopyandcsumbits() reaches unreadable frags it returns 0 after copying only the linear part, and the rest of the caller's buffer is left as it was. The callers copy into a buffer that is about to go out on the wire: an ICMP error quoting the offending packet, or a driver's TX bounce buffer in skbcopyandcsumdev(). Neither buffer is zeroed beforehand, so whatever was in memory there gets sent.
Zero the part of the buffer we didn't fill. The checksum usually won't match the data any more, so the receiver will usually drop the packet, but either way it no longer carries anything it shouldn't. Only zero for a positive @len, a negative one from a broken caller must not turn into a huge memset().
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In skb_copy_and_csum_bits(), zero the portion of the destination buffer that was not filled when unreadable fragments cause the function to return 0, preventing stale bytes from being sent or included in quoted packets.