blob: ab99391a3f83d8e7ac7e89274a04ff30bdc10236 [file] [log] [blame]
// Copyright 2021 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
{
include: [
"inspect/offer.shard.cml",
"syslog/offer.shard.cml",
"trace/offer.shard.cml",
],
children: [
{
name: "dhcpd",
url: "fuchsia-pkg://fuchsia.com/dhcpv4-server#meta/dhcpv4_server.cm",
},
{
name: "dhcpv6-client",
url: "fuchsia-pkg://fuchsia.com/dhcpv6-client#meta/dhcpv6-client.cm",
},
{
name: "dns-resolver",
url: "fuchsia-pkg://fuchsia.com/dns-resolver#meta/dns_resolver.cm",
},
{
name: "http-client",
url: "fuchsia-pkg://fuchsia.com/http-client#meta/http-client.cm",
},
{
name: "reachability",
url: "fuchsia-pkg://fuchsia.com/reachability#meta/reachability.cm",
startup: "eager",
},
],
offer: [
{
protocol: [
"fuchsia.scheduler.deprecated.ProfileProvider",
"fuchsia.scheduler.RoleManager",
],
from: "parent",
to: [ "#netstack" ],
},
{
protocol: [ "fuchsia.scheduler.RoleManager" ],
from: "parent",
to: [ "#dns-resolver" ],
},
{
protocol: [ "fuchsia.stash.SecureStore" ],
from: "parent",
to: [
"#dhcpd",
"#netstack",
],
},
{
protocol: [ "fuchsia.diagnostics.persist.DataPersistence-netstack" ],
from: "parent/diagnostics-persist-capabilities",
as: "fuchsia.diagnostics.persist.DataPersistence",
to: [ "#netstack" ],
},
{
protocol: [ "fuchsia.metrics.MetricEventLoggerFactory" ],
from: "parent",
to: [ "#reachability" ],
},
{
protocol: [ "fuchsia.net.dhcp.Server" ],
from: "#dhcpd",
to: [ "#netcfg" ],
},
{
protocol: [ "fuchsia.net.dhcpv6.ClientProvider" ],
from: "#dhcpv6-client",
to: [ "#netcfg" ],
},
{
protocol: "fuchsia.net.dhcp.ClientProvider",
// TODO(https://fxbug.dev/42076541): Once the DHCP client component is
// being used for all DHCPv4 functionality, make it a child of this
// realm, route the protocol from there instead of the netstack
// realm, and mark it here as "required".
from: "#netstack",
to: "#netcfg",
availability: "same_as_target",
},
{
protocol: [ "fuchsia.net.filter.Control" ],
// NS2 will not implement fuchsia.net.filter, mark as optional.
from: "#netstack",
to: "#netcfg",
availability: "same_as_target",
},
{
protocol: [ "fuchsia.net.name.Lookup" ],
from: "#dns-resolver",
to: [
"#dhcpd",
"#http-client",
"#reachability",
],
},
{
protocol: [ "fuchsia.net.name.LookupAdmin" ],
from: "#dns-resolver",
to: [ "#netcfg" ],
},
{
protocol: [
"fuchsia.net.interfaces.admin.Installer",
"fuchsia.net.name.DnsServerWatcher",
"fuchsia.net.ndp.RouterAdvertisementOptionWatcherProvider",
"fuchsia.net.routes.admin.RouteTableV4",
"fuchsia.net.routes.admin.RouteTableV6",
"fuchsia.net.routes.admin.RuleTableV4",
"fuchsia.net.routes.admin.RuleTableV6",
"fuchsia.net.stack.Stack",
],
from: "#netstack",
to: [ "#netcfg" ],
},
{
protocol: [ "fuchsia.net.interfaces.State" ],
from: "#netstack",
to: [
"#netcfg",
"#reachability",
],
},
{
protocol: [
"fuchsia.net.routes.StateV4",
"fuchsia.net.routes.StateV6",
],
from: "#netstack",
to: [ "#reachability" ],
},
{
protocol: [ "fuchsia.net.routes.State" ],
from: "#netstack",
to: [ "#dns-resolver" ],
},
{
protocol: [ "fuchsia.posix.socket.packet.Provider" ],
from: "#netstack",
to: [ "#dhcpd" ],
},
{
protocol: [
"fuchsia.net.debug.Diagnostics",
"fuchsia.net.debug.Interfaces",
"fuchsia.net.neighbor.View",
],
from: "#netstack",
to: [ "#reachability" ],
},
{
// TODO(https://fxbug.dev/324273348): Remove this capability once the clients have
// been migrated to services. The service capability has been added below.
directory: "dev-class-network",
from: "parent",
to: [ "#netcfg" ],
},
{
// This service replaces the directory capability above.
service: "fuchsia.hardware.network.Service",
from: "parent",
to: [ "#netcfg" ],
},
{
directory: "config-data",
from: "parent",
to: "#netcfg",
subdir: "netcfg",
},
{
directory: "config-data",
from: "parent",
to: "#netstack",
subdir: "netstack",
},
{
directory: "root-ssl-certificates",
from: "parent",
to: [ "#http-client" ],
},
{
config: "fuchsia.http-client.StopOnIdleTimeoutMillis",
from: "parent",
to: "#http-client",
availability: "same_as_target",
},
{
protocol: [
"fuchsia.power.broker.Topology",
"fuchsia.power.system.ActivityGovernor",
],
from: "parent",
to: "#netstack",
availability: "same_as_target",
},
{
config: "fuchsia.power.SuspendEnabled",
from: "parent",
to: "#netstack",
},
{
storage: "cache",
from: "parent",
to: [ "#netstack" ],
},
{
storage: "data",
from: "parent",
to: [
"#netcfg",
"#netstack",
],
},
],
expose: [
{
protocol: [
"fuchsia.net.debug.Interfaces",
"fuchsia.net.interfaces.admin.Installer",
"fuchsia.net.interfaces.State",
"fuchsia.net.multicast.admin.Ipv6RoutingTableController",
"fuchsia.net.ndp.RouterAdvertisementOptionWatcherProvider",
"fuchsia.net.root.Interfaces",
"fuchsia.net.routes.admin.RouteTableProviderV4",
"fuchsia.net.routes.admin.RouteTableProviderV6",
"fuchsia.net.routes.admin.RouteTableV4",
"fuchsia.net.routes.admin.RouteTableV6",
"fuchsia.net.routes.admin.RuleTableV4",
"fuchsia.net.routes.admin.RuleTableV6",
"fuchsia.net.routes.State",
"fuchsia.net.routes.StateV4",
"fuchsia.net.routes.StateV6",
"fuchsia.net.stack.Stack",
"fuchsia.posix.socket.packet.Provider",
],
from: "#netstack",
},
{
protocol: [
"fuchsia.net.filter.Control",
"fuchsia.net.filter.SocketControl",
],
from: "#netstack",
availability: "same_as_target",
},
{
protocol: [ "fuchsia.net.name.Lookup" ],
from: "#dns-resolver",
},
{
protocol: [ "fuchsia.net.http.Loader" ],
from: "#http-client",
},
{
protocol: [ "fuchsia.net.reachability.Monitor" ],
from: "#reachability",
},
{
protocol: [
"fuchsia.net.dhcpv6.PrefixProvider",
"fuchsia.net.masquerade.Factory",
"fuchsia.net.name.DnsServerWatcher",
],
from: "#netcfg",
},
],
}