Module options

Source
Expand description

Utilities for parsing the options formats in protocols like IPv4, TCP, and NDP.

This module provides parsing utilities for type-length-value-like records encodings like those used by the options in an IPv4 or TCP header or an NDP packet. These formats are not identical, but share enough in common that the utilities provided here only need a small amount of customization by the user to be fully functional.

Structs§

OptionParseErr
An error encountered while parsing an option or sequence of options.

Enums§

LengthEncoding
Whether the length field of an option encodes the length of the entire option (including kind and length fields) or only of the value field.

Traits§

AlignedOptionBuilder
A builder capable of serializing an option with an alignment requirement.
KindLenField
The type of the “kind” and “length” fields in an option.
OptionBuilder
A builder capable of serializing an option.
OptionLayout
Information about an option’s layout.
OptionParseError
An error encountered while parsing an option or sequence of options.
OptionParseLayout
Information about an option’s layout required in order to parse it.
OptionsImpl
An implementation of an options parser.

Type Aliases§

AlignedOptionSequenceBuilder
A builder capable of serializing a sequence of aligned options.
OptionSequenceBuilder
A builder capable of serializing a sequence of options.
Options
A parsed sequence of options.
OptionsRaw
A not-yet-parsed sequence of options.