Init()
Initializes the routing manager on given infrastructure interface.
SetEnabled()
Enables/disables the Border Routing Manager.
IsRunning() const
Indicates whether or not it is currently running. In order for the `RoutingManager` to be running it needs to be initialized and enabled, and device being attached.
GetState() const
Gets the state of `RoutingManager`.
RequestStop()
Requests the Border Routing Manager to stop. If Border Routing Manager is running, calling this method immediately stops it and triggers the preparation and sending of a final Router Advertisement (RA) message on infrastructure interface which deprecates and/or removes any previously advertised PIO/RIO prefixes. If Routing Manager is not running (or not enabled), no action is taken. Note that this method does not change whether the Routing Manager is enabled or disabled (see `SetEnabled()`). It stops the Routing Manager temporarily. After calling this method if the device role gets changes (device gets attached) and/or the infra interface state gets changed, the Routing Manager may be started again.
GetRouteInfoOptionPreference() const
Gets the current preference used when advertising Route Info Options (RIO) in Router Advertisement messages sent over the infrastructure link. The RIO preference is determined as follows: - If explicitly set by user by calling `SetRouteInfoOptionPreference()`, the given preference is used. - Otherwise, it is determined based on device's role: Medium preference when in router/leader role and low preference when in child role.
SetRouteInfoOptionPreference()
Explicitly sets the preference to use when advertising Route Info Options (RIO) in Router Advertisement messages sent over the infrastructure link. After a call to this method, BR will use the given preference for all its advertised RIOs. The preference can be cleared by calling `ClearRouteInfoOptionPreference`()`.
ClearRouteInfoOptionPreference()
Clears a previously set preference value for advertised Route Info Options. After a call to this method, BR will use device role to determine the RIO preference: Medium preference when in router/leader role and low preference when in child role.
Sets additional options to append at the end of emitted Router Advertisement (RA) messages. The content of @p aOptions is copied internally, so can be a temporary stack variable. Subsequent calls to this method will overwrite the previously set value.
GetRoutePreference() const
Gets the current preference used for published routes in Network Data. The preference is determined as follows: - If explicitly set by user by calling `SetRoutePreference()`, the given preference is used. - Otherwise, it is determined automatically by `RoutingManager` based on the device's role and link quality.
SetRoutePreference()
Explicitly sets the preference of published routes in Network Data. After a call to this method, BR will use the given preference. The preference can be cleared by calling `ClearRoutePreference`()`.
ClearRoutePreference()
Clears a previously set preference value for published routes in Network Data. After a call to this method, BR will determine the preference automatically based on the device's role and link quality (to the parent when acting as end-device).
GetOmrPrefix() const
Returns the local generated off-mesh-routable (OMR) prefix. The randomly generated 64-bit prefix will be added to the Thread Network Data if there isn't already an OMR prefix.
GetFavoredOmrPrefix() const
Returns the currently favored off-mesh-routable (OMR) prefix. The favored OMR prefix can be discovered from Network Data or can be our local OMR prefix. An OMR prefix with higher preference is favored. If the preference is the same, then the smaller prefix (in the sense defined by `Ip6::Prefix`) is favored.
GetOnLinkPrefix() const
Returns the on-link prefix for the adjacent infrastructure link. The randomly generated 64-bit prefix will be advertised on the infrastructure link if there isn't already a usable on-link prefix being advertised on the link.
GetFavoredOnLinkPrefix() const
Returns the favored on-link prefix for the adjacent infrastructure link. The favored prefix is either a discovered prefix on the infrastructure link or the local on-link prefix.
GetNat64PrefixManagerState() const
Gets the state of NAT64 prefix publishing.
SetNat64PrefixManagerEnabled()
Enable or disable NAT64 prefix publishing.
GetNat64Prefix()
Returns the local NAT64 prefix.
GetFavoredNat64Prefix()
Returns the currently favored NAT64 prefix. The favored NAT64 prefix can be discovered from infrastructure link or can be the local NAT64 prefix.
HandleDiscoverNat64PrefixDone()
Informs `RoutingManager` of the result of the discovery request of NAT64 prefix on infrastructure interface (`InfraIf::DiscoverNat64Prefix()`).
HandleReceived()
Processes a received ICMPv6 message from the infrastructure interface. Malformed or undesired messages are dropped silently.
HandleInfraIfStateChanged()
Handles infrastructure interface state changes.
IsValidOmrPrefix()
Checks whether the on-mesh prefix configuration is a valid OMR prefix.
IsValidOmrPrefix()
Checks whether the on-mesh prefix configuration is a valid OMR prefix.
InitPrefixTableIterator() const
Initializes a `PrefixTableIterator`. An iterator can be initialized again to start from the beginning of the table. When iterating over entries in the table, to ensure the entry update times are consistent, they are given relative to the time the iterator was initialized.
GetNextPrefixTableEntry() const
Iterates over entries in the discovered prefix table.
GetNextRouterEntry() const
Iterates over discovered router entries on infrastructure link.
GetNextPeerBrEntry() const
Iterates over the peer BRs found in the Network Data.
CountPeerBrs() const
Returns the number of peer BRs found in the Network Data. The count does not include this device itself (when it itself is acting as a BR).
HandleSrpServerAutoEnableMode()
Determines whether to enable/disable SRP server when the auto-enable mode is changed on SRP server. This should be called from `Srp::Server` when auto-enable mode is changed.
CheckReachabilityToSendIcmpError()
Determines whether to send an ICMPv6 Destination Unreachable error to the sender based on reachability and source address. Specifically, if the Border Router (BR) decides to forward a unicast IPv6 message outside the AIL and the message's source address matches a BR-generated ULA OMR prefix (with low preference), and the destination is unreachable using this source address, then an ICMPv6 Destination Unreachable message is sent back to the sender.
HandleRxRaTrackerSignalTask()
HandleRxRaTrackerExpirationTimer()
HandleRxRaTrackerStaleTimer()
HandleRxRaTrackerRouterTimer()
HandleOnLinkPrefixManagerTimer()
HandleRioAdvertiserimer()
HandleNat64PrefixManagerTimer()
HandleRoutePublisherTimer()
HandleRsSenderTimer()
EvaluateState()
Start()
Stop()
HandleNotifierEvents()
IsInitialized() const
IsEnabled() const
LoadOrGenerateRandomBrUlaPrefix()
EvaluateRoutingPolicy()
IsInitialPolicyEvaluationDone() const
ScheduleRoutingPolicyEvaluation()
HandleRsSenderFinished()
SendRouterAdvertisement()
HandleRouterAdvertisement()
HandleRouterSolicit()
HandleNeighborAdvertisement()
NetworkDataContainsUlaRoute() const
HandleRaPrefixTableChanged()
HandleLocalOnLinkPrefixChanged()
CalculateExpirationTime()
IsValidBrUlaPrefix()
IsValidOnLinkPrefix()
IsValidOnLinkPrefix()
LogPrefixInfoOption()
LogRouteInfoOption()
RouterAdvOriginToString()