Skip to main content

Module tcp

Module tcp 

Source
Expand description

Parsing and serialization of TCP segments.

The TCP segment format is defined in [RFC 791 Section 3.3].

Modules§

options
Parsing and serialization of TCP options.

Structs§

TcpEnvelope
TCP segment context relevant to serialization.
TcpFlowAndSeqNum
Contains the TCP flow info and its sequence number.
TcpFlowHeader
The minimal information required from a TCP segment header.
TcpOptionsTooLongError
Options provided to TcpSegmentBuilderWithOptions::new exceed MAX_OPTIONS_LEN when serialized.
TcpParseArgs
Arguments required to parse a TCP segment.
TcpSegment
A TCP segment.
TcpSegmentBuilder
A builder for TCP segments.
TcpSegmentBuilderWithOptions
A builder for TCP segments with options
TcpSegmentRaw
A partially-parsed and not yet validated TCP segment.

Constants§

CHECKSUM_OFFSET
The offset of the checksum field, in bytes, from the start of a TCP header.
HDR_PREFIX_LEN
The length of the fixed prefix of a TCP header (preceding the options).
MAX_HDR_LEN
The maximum length of a TCP header.
MAX_OPTIONS_LEN
The maximum length of the options in a TCP header.

Traits§

TcpParseContext
Context for parsing TCP segments that may be subject to hardware checksum offloading.
TcpSerializationContext
A trait for TCP serialization contexts.