firewire: net: Fix fragmented datagram reassembly
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ c76acec6d55107b652a37c90b36c00bc8b04dabb · < 0177e578d7a885037b0fb82286c12e9d0360cc10| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
firewire: net: Fix fragmented datagram reassembly
fwnet_frag_new() keeps a sorted list of received fragments for a partial datagram. When a new fragment is adjacent to an existing fragment, the code checks whether the new fragment also closes the gap to the next or previous list entry.
Those neighbor lookups currently assume that the current fragment always has a real next or previous fragment. At a list edge, the next or previous entry is the list head, not a struct fwnet_fragment_info.
The gap checks also compare against the old edge of the current fragment instead of the edge after adding the new fragment. As a result, a fragment that bridges two existing ranges may leave two adjacent ranges unmerged, so fwnet_pd_is_complete() can miss a complete datagram.
Check for the list head before looking up the neighboring fragment, and compare the neighbor against the new fragment's far edge when deciding whether to merge all three ranges.
This issue was found by a static analysis checker and confirmed by manual source review.
From the CVE record · Linux
The Linux kernel’s FireWire net code mishandles adjacent fragments and list edges during datagram reassembly. A fragment bridging existing ranges can leave a complete datagram unrecognized; neighbor lookups can also treat the list head as a fragment. The input does not establish attacker access, authentication requirements, or user interaction.
Engineers running Linux kernels with FireWire net support should check their kernels; affected versions are not specified.