Crate netstack3_ip

Source
Expand description

Netstack3 core IP layer.

This crate contains the IP layer for netstack3.

Modules§

device
Definitions for devices at the IP layer.
gmp
Group management protocols.
icmp
The Internet Control Message Protocol (ICMP).
marker
Marker traits controlling IP context behavior.
multicast_forwarding
Multicast Forwarding
nud
Neighbor Unreachability Detection.
raw
Raw IP sockets.
socket
IP Layer definitions supporting sockets.

Structs§

AddableEntry
AddableEntry is a routing entry that may be used to add a new entry to the forwarding table.
Destination
The destination of an outbound IP packet.
DeviceIpLayerMetadata
Metadata that is produced and consumed by the IP layer for each packet, but which also traverses the device layer.
Entry
A forwarding entry.
FragmentTimerId
The timer ID for the fragment cache.
FragmentationCounters
Counters kept by the IP stack pertaining to fragmentation.
Generation
Used to compare routes for how early they were added to the table.
HopLimits
Hop limits for packets sent to multicast and unicast destinations.
IpCounters
Ip layer counters.
IpPacketFragmentCache
A cache of inbound IP packet fragments.
IpStateInner
The inner state for the IP layer for IP version I.
Ipv4State
The stack’s IPv4 state.
Ipv4StateBuilder
A builder for IPv4 state.
Ipv6State
The stack’s IPv6 state.
Ipv6StateBuilder
A builder for IPv6 state.
LocalDeliveryPacketInfo
Information for an incoming packet.
MarkMatchers
The 2 mark matchers a rule can specify. All non-none markers must match.
PmtuCache
A path MTU cache.
RawMetric
The priority of a forwarding entry. Lower metrics are preferred.
ReceiveIpPacketMeta
Meta information for an incoming packet.
ResolvedRoute
The resolved route to a destination IP address.
RouteResolveOptions
The options for RoutesApi::resolve_route api.
RouterAdvertisementEvent
An event signifying a router advertisement has been received.
RoutesAnyApi
The routes API interacting with all IP versions.
RoutesApi
The routes API for a specific IP version I.
RoutingTable
An IP routing table.
RoutingTableId
Identifier to a routing table.
Rule
A routing rule.
RuleMatcher
Contains traffic matchers for a given rule.
RulesTable
Table that contains routing rules.
SendIpPacketMeta
The metadata associated with an outgoing IP packet.
TransparentLocalDelivery
Informs the transport layer of parameters for transparent local delivery.

Enums§

AddRouteError
An error encountered when adding a routing entry.
AddableEntryEither
An IPv4 forwarding entry or an IPv6 forwarding entry.
AddableMetric
The metric for an AddableEntry.
AddressStatus
The status of an IP address on an interface.
BoundDeviceMatcher
Matcher for the bound device of locally generated traffic.
DropReason
The reason a received IP packet is dropped.
EntryEither
An IPv4 forwarding entry or an IPv6 forwarding entry.
InternalForwarding
Internal forwarding semantics.
IpLayerEvent
Events observed at the IP layer.
IpLayerTimerId
The identifier for timer events in the IP layer.
IpPacketDestination
Packed destination passed to IpDeviceSendContext::send_ip_frame.
IpSendFrameErrorReason
Send error cause for IpSendFrameError.
Ipv4PresentAddressStatus
The status of an IPv4 address.
Ipv6PresentAddressStatus
The status of an IPv6 address.
MarkMatcher
A matcher to the socket mark.
Metric
The metric for an Entry.
NextHop
The next hop for a Destination.
NonLocalSrcAddrPolicy
Tells whether a non local IP address is allowed as the source address for route selection.
PacketOrigin
Tells whether the packet being routed is generated by us or someone else.
ReceivePacketAction
The action to take in order to process a received IP packet.
ResolveRouteError
An error occurred while resolving the route to a destination
RuleAction
The action part of a Rule.
TrafficOriginMatcher
Matches with PacketOrigin.
TransportReceiveError
An error encountered when receiving a transport-layer packet.

Constants§

DEFAULT_HOP_LIMITS
Default hop limits for sockets.
DEFAULT_TTL
Default IPv4 TTL.
IPV6_DEFAULT_SUBNET
The IPv6 subnet that contains all addresses; ::/0.

Traits§

BaseTransportIpContext
The base execution context provided by the IP layer to transport layer protocols.
FilterHandlerProvider
Abstracts access to a filter::FilterHandler for core contexts.
FragmentContext
The state context for the fragment cache.
IpDeviceConfirmReachableContext
Provides the ability to check neighbor reachability via a specific device.
IpDeviceContext
The IP device context provided to the IP layer.
IpDeviceEgressStateContext
Provides access to an IP device’s state for IP layer egress.
IpDeviceIngressStateContext
Provides access to an IP device’s state for IP layer ingress.
IpDeviceMtuContext
Provides access to an IP device’s MTU for the IP layer.
IpHeaderInfo
Abstracts extracting information from IP headers for upper layers.
IpLayerBindingsContext
The bindings execution context for the IP layer.
IpLayerContext
The execution context for the IP layer.
IpLayerHandler
Trait for abstracting the IP layer for locally-generated traffic. That is, traffic generated by the netstack itself (e.g. ICMP, IGMP, or MLD).
IpLayerIpExt
An extension trait providing IP layer properties.
IpRouteTableContext
The state context that gives access to a singular routing table.
IpRouteTablesContext
The state context that gives access to routing tables provided to the IP layer.
IpRoutingDeviceContext
Provides access to a device for the purposes of IP routing.
IpSasHandler
A handler for Source Address Selection.
IpStateContext
The state context provided to the IP layer.
IpTransportContext
The execution context provided by a transport layer protocol to the IP layer.
IpTransportDispatchContext
The IP context providing dispatch to the available transport protocols.
MulticastMembershipHandler
Abstraction over the ability to join and leave multicast groups.
NdpBindingsContext
Ipv6-specific bindings execution context for the IP layer.
PmtuContext
The core context for the path MTU cache.
TransportIpContext
A marker trait for the traits required by the transport layer from the IP layer.

Functions§

gen_ip_packet_id
Generates an IP packet ID.
receive_ipv4_packet
Receive an IPv4 packet from a device.
receive_ipv4_packet_action
Computes the action to take in order to process a received IPv4 packet.
receive_ipv6_packet
Receive an IPv6 packet from a device.
receive_ipv6_packet_action
Computes the action to take in order to process a received IPv6 packet.
request_context_add_route
Requests that a route be added to the routing table.
request_context_del_routes
Requests that routes matching these specifiers be removed from the routing table.
resolve_output_route_to_destination
Returns the outgoing routing instructions for reaching the given destination.

Type Aliases§

IpSendFrameError
Send errors observed at or above the IP layer that carry a serializer.
RoutableIpAddr
An IP Address that witnesses properties needed to be routed.