PROTOCOLS
State
Defined in fuchsia.net.routes/routes.fidl
Provides access to the system's routing state.
Resolve
Resolves the route to a destination.
- request
destination
the IP address to resolve a route to. If the unspecified address (all zeroes) is provided, the default route will be returned. The variant ofdestination
determines variant of fuchsia.net/IpAddress fields in the resolved route.
- response
result
contains the resolved route todestination
.
- error
ZX_ERR_ADDRESS_UNREACHABLE
ifdestination
can't be resolved.
Request
Name | Type |
---|---|
destination |
fuchsia.net/IpAddress
|
Response
Name | Type |
---|---|
result |
State_Resolve_Result
|
STRUCTS
State_Resolve_Response
Defined in fuchsia.net.routes/routes.fidl
Name | Type | Description | Default |
---|---|---|---|
result |
Resolved
|
No default |
TABLES
Destination
Defined in fuchsia.net.routes/routes.fidl
Collection of addresses and identifiers describing a network destination.
A Destination
is the "next-hop" for a routed packet.
Ordinal | Name | Type | Description |
---|---|---|---|
1 | address |
fuchsia.net/IpAddress
|
The IP address of the destination. |
2 | mac |
fuchsia.net/MacAddress
|
The MAC address of the destination. Only set if the destination is on a link that requires a MAC address. |
3 | interface_id |
fuchsia.net/interface_id
|
The interface identifier over which the destination can be reached. |
4 | source_address |
fuchsia.net/IpAddress
|
The preferred local IP address used to communicate with the destination. |
UNIONS
Resolved
Defined in fuchsia.net.routes/routes.fidl
A resolved route.
Contains the information for the "next-hop" or immediate-destination that is the result of a route resolution. A resolved route is only meaningful in the context of a requested destination.
Name | Type | Description |
---|---|---|
direct |
Destination
|
The requested destination is directly reachable. |
gateway |
Destination
|
The requested destination is reachable through a gateway, thus the next hop is the gateway. |
State_Resolve_Result
Defined in fuchsia.net.routes/routes.fidl
Name | Type | Description |
---|---|---|
response |
State_Resolve_Response
|
|
err |
zx/status
|