Google is committed to advancing racial equity for Black communities. See how.

fuchsia.net.name

PROTOCOLS

DnsServerWatcher

Defined in fuchsia.net.name/server_watcher.fidl

Provides a hanging get interface to watch for DNS servers configuration.

WatchServers

Returns a list of DNS servers.

First call always returns a snapshot of the current list of servers or blocks if an empty list would be returned. Subsequent calls will block until the list of servers changes.

The list of servers changes over time by configuration or network topology changes, expiration, etc. Callers must repeatedly call WatchServers and replace any previously returned servers with new ones to avoid using stale or expired entries.

It is invalid to call this method while a previous call is pending. Doing so will cause the server end of the protocol to be closed.

  • response servers The list of servers to use for DNS resolution, in priority order.

Request

<EMPTY>

Response

NameType
servers vector<DnsServer>

Lookup

Defined in fuchsia.net.name/lookup.fidl

Provides name and address resolution.

LookupHostname

Look up a hostname by IP address.

Request

NameType
addr fuchsia.net/IpAddress

Response

NameType
result Lookup_LookupHostname_Result

LookupIp

Lookup a list of IP addresses by hostname.

If hostname is an Internationalized Domain Name, it must be encoded as per RFC 3490.

Request

NameType
hostname fuchsia.net/Hostname
options LookupIpOptions

Response

NameType
result Lookup_LookupIp_Result

LookupAdmin

Defined in fuchsia.net.name/lookup_admin.fidl

Provides administration controls over name resolution settings.

GetDnsServers

Gets the DNS servers currently in use to resolve name lookups.

  • response servers The list of servers in use by LookupAdmin, in priority order.

Request

<EMPTY>

Response

NameType
servers vector<fuchsia.net/SocketAddress>

SetDnsServers

Sets the DNS servers to servers

  • request servers The list of servers to use for domain name resolution, in priority order. An empty list means no servers will be used and name resolution may fail. Each SocketAddress in servers must be a valid unicast socket address. The list of servers will be deduplicated.
  • error Returns ZX_ERR_INVALID_ARGS if any of the provided addresses does not meet the conditions above.

Request

NameType
servers vector<fuchsia.net/SocketAddress>

Response

NameType
result LookupAdmin_SetDnsServers_Result

STRUCTS

LookupAdmin_SetDnsServers_Response

Defined in fuchsia.net.name/lookup_admin.fidl

<EMPTY>

Lookup_LookupHostname_Response

Defined in fuchsia.net.name/lookup.fidl

FieldTypeDescriptionDefault
hostname fuchsia.net/Hostname No default

Lookup_LookupIp_Response

Defined in fuchsia.net.name/lookup.fidl

FieldTypeDescriptionDefault
result LookupResult No default

ENUMS

LookupError strict

Type: uint32

Defined in fuchsia.net.name/lookup.fidl

Lookup operation errors.

NameValueDescription
NOT_FOUND 1

No result was found for this query.

TRANSIENT 2

The lookup failed, but may succeed at a later time. For instance, the network or DNS server may be unreachable.

INVALID_ARGS 3

The lookup failed due to an invalid argument (for instance, the hostname was not encoded correctly, or was too long).

INTERNAL_ERROR 4

The lookup failed due to an internal error.

TABLES

DhcpDnsServerSource

Defined in fuchsia.net.name/dns.fidl

OrdinalFieldTypeDescription
1 source_interface uint64

The interface index over which this server was discovered.

Dhcpv6DnsServerSource

Defined in fuchsia.net.name/dns.fidl

OrdinalFieldTypeDescription
1 source_interface uint64

The interface index over which this server was discovered.

DnsServer

Defined in fuchsia.net.name/dns.fidl

A DNS server configuration.

OrdinalFieldTypeDescription
1 address fuchsia.net/SocketAddress

The server's address, must be provided.

2 source DnsServerSource

The configuration source for this server. Defaults to fuchsia.net.name/DnsServerSource.static_source.

LookupIpOptions

Defined in fuchsia.net.name/lookup.fidl

OrdinalFieldTypeDescription
1 ipv4_lookup bool

Include IPv4 results.

If not set, interpreted as false.

2 ipv6_lookup bool

Include IPv6 results.

If not set, interpreted as false.

3 sort_addresses bool

Sort addresses in order of preference.

It true, Addresses are sorted according to destination address selection described in RFC 6724 Section 6.

If not set, interpreted as false.

LookupResult

Defined in fuchsia.net.name/lookup.fidl

OrdinalFieldTypeDescription
1 addresses vector<fuchsia.net/IpAddress>

The IP addresses resulting from a lookup.

If sorting was requested, addresses is sorted in order of preference, most preferred destination address first.

NdpDnsServerSource

Defined in fuchsia.net.name/dns.fidl

OrdinalFieldTypeDescription
1 source_interface uint64

The interface index over which this server was discovered.

StaticDnsServerSource

Defined in fuchsia.net.name/dns.fidl

OrdinalFieldTypeDescription

UNIONS

DnsServerSource strict

Defined in fuchsia.net.name/dns.fidl

Ordinal
VariantTypeDescription
1 static_source StaticDnsServerSource

The server is statically configured through fuchsia.net.name/LookupAdmin.SetDefaultServers.

2 dhcp DhcpDnsServerSource

The server was discovered through DHCPv4.

3 ndp NdpDnsServerSource

The server was discovered through an NDP Router Advertisement.

4 dhcpv6 Dhcpv6DnsServerSource

The server was discovered through DHCPv6.

LookupAdmin_SetDnsServers_Result strict

Defined in fuchsia.net.name/lookup_admin.fidl

Ordinal
VariantTypeDescription
1 response LookupAdmin_SetDnsServers_Response
2 err zx/status

Lookup_LookupHostname_Result strict

Defined in fuchsia.net.name/lookup.fidl

Ordinal
VariantTypeDescription
1 response Lookup_LookupHostname_Response
2 err LookupError

Lookup_LookupIp_Result strict

Defined in fuchsia.net.name/lookup.fidl

Ordinal
VariantTypeDescription
1 response Lookup_LookupIp_Response
2 err LookupError