From 758e45618f3d663a092b31baf29f24b3e4dc4d54 Mon Sep 17 00:00:00 2001 From: Toshi Kikuchi Date: Mon, 16 Nov 2020 13:05:01 -0800 Subject: Clean up fragmentation.Process - Pass a PacketBuffer directly instead of releaseCB - No longer pass a VectorisedView, which is included in the PacketBuffer - Make it an error if data size is not equal to (last - first + 1) - Set the callback for the reassembly timeout on NewFragmentation PiperOrigin-RevId: 342702432 --- pkg/tcpip/header/parse/parse.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'pkg/tcpip/header') diff --git a/pkg/tcpip/header/parse/parse.go b/pkg/tcpip/header/parse/parse.go index 5ca75c834..2042f214a 100644 --- a/pkg/tcpip/header/parse/parse.go +++ b/pkg/tcpip/header/parse/parse.go @@ -109,6 +109,9 @@ traverseExtensions: fragOffset = extHdr.FragmentOffset() fragMore = extHdr.More() } + rawPayload := it.AsRawHeader(true /* consume */) + extensionsSize = dataClone.Size() - rawPayload.Buf.Size() + break traverseExtensions case header.IPv6RawPayloadHeader: // We've found the payload after any extensions. -- cgit v1.2.3