Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
datapath-windows: Fix parsing of split buffers in OvsGetTcpHeader.
NdisGetDataBuffer() is called without providing a buffer to copy packet data in case it is not contiguous. So, it fails in some scenarios where the packet is handled by the general network stack before OVS and headers become split in multiple buffers. Use existing helpers to retrieve the headers instead, they are using OvsGetPacketBytes() which should be able to handle split data. It might be a bit slower than getting direct pointers that may be provided by NdisGetDataBuffer(), but it's better to optimize commonly used OvsGetPacketBytes() helper in the future instead of optimizing every single caller separately. And we're still copying the TCP header anyway. Fixes: 9726a01 ("datapath-windows: Implement locking in conntrack NAT.") Reported-at: openvswitch/ovs-issues#323 Signed-off-by: Ilya Maximets <[email protected]> Signed-off-by: 0-day Robot <[email protected]>
- Loading branch information