pub fn extract_tcp(payload: &[u8]) -> Option<TcpSegment<'_>>Expand description
Extracts ports and payload from an IP payload whose protocol is
PROTO_TCP, accounting for the variable-length TCP header
(data offset field) so that TCP options don’t leak into payload.