In the Linux kernel, the following vulnerability has been resolved: net: skbuff: don't BUG() on a bad csum_start in skb_copy_and_csum_dev() skb_copy_and_csum_dev() copies everything up to the checksum start out of the linear area, and BUG()s if the checksum start is past the end of the linear area. It misses the other direction: a CHECKSUM_PARTIAL skb that has been pulled past its csum_start gives a negative offset, which gets past the check and becomes a ~4GB copy. It also trusts csum_offset when it stores the folded checksum. So far skb_copy_and_csum_bits() BUG()ing on a short skb has covered for that, but once it returns instead, a bad csum_offset would write past the end of the caller's buffer. The function returns void and its callers are drivers copying a frame into a bounce buffer just before handing it to the hardware. There's nothing for them to back out of, so check both ends of csum_start and that the checksum field fits in the frame, and if not, copy the whole frame with skb_copy_bits() without filling in the checksum, with a DEBUG_NET_WARN_ON_ONCE() for debug kernels. The frame goes out with a bad checksum and is dropped by the receiver. If even that copy fails, zero the buffer so the driver doesn't send stale bytes.
https://git.kernel.org/stable/c/fbe0784189f28079a23991e1fc385efcaf7beb8a
https://git.kernel.org/stable/c/f31a1f4c18edba84b61c016f3d68fe5f945b75e2
https://git.kernel.org/stable/c/c59aeb403f6cc4205a9ebb7217e7d3ec62624bf1
https://git.kernel.org/stable/c/8c0d59fd1402c989fe6ec1ab3a015b3e2974862d
https://git.kernel.org/stable/c/818fb17d609baf8e9646425c3efea6beba14379b
https://git.kernel.org/stable/c/77ef7f1d47d50501f4730075ede2bad23ca84d03
https://git.kernel.org/stable/c/5fe6757584ab7fdeeb2bbd3b82120769dcdbacd9
https://git.kernel.org/stable/c/56453199d28f0072a8196fba14b2d702632e2219