Skip to main content

Module flowspec

Module flowspec 

Source
Expand description

FlowSpec NLRI types and codec (RFC 8955 / RFC 8956). RFC 8955 / RFC 8956 FlowSpec NLRI codec and types.

FlowSpec rules consist of ordered match components (type-value pairs) that describe traffic to filter. Each component uses either numeric operators (ports, protocol, length, DSCP) or bitmask operators (TCP flags, fragment).

The wire format uses a length-prefixed TLV structure with operator bytes that encode comparison semantics and value sizes.

Structs§

BitmaskMatch
A single bitmask comparison term.
FlowSpecRule
A complete FlowSpec NLRI rule — an ordered set of match components.
Ipv6PrefixOffset
IPv6 prefix with an additional bit offset for FlowSpec source/destination.
NumericMatch
A single numeric comparison term with operator flags and a value.

Enums§

FlowSpecAction
A traffic action decoded from a FlowSpec extended community.
FlowSpecComponent
A single FlowSpec match component.
FlowSpecPrefix
Prefix value for FlowSpec destination/source components.

Functions§

decode_flowspec_nlri
Decode one or more FlowSpec NLRI rules from wire bytes.
encode_flowspec_nlri
Encode FlowSpec NLRI rules to wire bytes.