Move NetworkStack AIDLs to NetworkStack folder

The AIDLs and ipmemorystore-client were already statically linked
libraries, so their location in the source tree does not change anything
(they were already built into the NetworkStack module and the
framework). It makes more sense to have them in the NetworkStack module
folder however, as changes to these files will be released with the same
cadence as the module, not the framework.

Bug: 139106271
Test: built, flashed, WiFi working
Change-Id: I886acae850a5e8a9a7bc3ca8aac8690d681ca2cd
This commit is contained in:
Remi NGUYEN VAN
2019-08-08 15:49:46 +09:00
parent 4339cf3402
commit ee27a94773
113 changed files with 1 additions and 3116 deletions

View File

@@ -1,87 +1,10 @@
// AIDL interfaces between the core system and the networking mainline module.
aidl_interface {
name: "ipmemorystore-aidl-interfaces",
local_include_dir: "java",
srcs: [
"java/android/net/IIpMemoryStore.aidl",
"java/android/net/IIpMemoryStoreCallbacks.aidl",
"java/android/net/ipmemorystore/**/*.aidl",
],
backend: {
ndk: {
enabled: false,
},
cpp: {
enabled: false,
},
},
api_dir: "aidl/ipmemorystore",
versions: [
"1",
"2",
"3",
],
}
aidl_interface {
name: "networkstack-aidl-interfaces",
local_include_dir: "java",
include_dirs: ["frameworks/base/core/java"], // For framework parcelables.
srcs: [
"java/android/net/DhcpResultsParcelable.aidl",
"java/android/net/INetworkMonitor.aidl",
"java/android/net/INetworkMonitorCallbacks.aidl",
"java/android/net/INetworkStackConnector.aidl",
"java/android/net/INetworkStackStatusCallback.aidl",
"java/android/net/InitialConfigurationParcelable.aidl",
"java/android/net/NattKeepalivePacketDataParcelable.aidl",
"java/android/net/PrivateDnsConfigParcel.aidl",
"java/android/net/ProvisioningConfigurationParcelable.aidl",
"java/android/net/TcpKeepalivePacketDataParcelable.aidl",
"java/android/net/dhcp/DhcpServingParamsParcel.aidl",
"java/android/net/dhcp/IDhcpServer.aidl",
"java/android/net/dhcp/IDhcpServerCallbacks.aidl",
"java/android/net/ip/IIpClient.aidl",
"java/android/net/ip/IIpClientCallbacks.aidl",
],
backend: {
ndk: {
enabled: false,
},
cpp: {
enabled: false,
},
},
api_dir: "aidl/networkstack",
imports: ["ipmemorystore-aidl-interfaces"],
versions: [
"1",
"2",
"3",
],
}
java_library_static {
name: "services.net",
srcs: ["java/**/*.java"],
static_libs: [
"dnsresolver_aidl_interface-V2-java",
"ipmemorystore-client",
"netd_aidl_interface-java",
"networkstack-aidl-interfaces-V3-java",
],
}
java_library_static {
name: "ipmemorystore-client",
sdk_version: "system_current",
srcs: [
":framework-annotations",
"java/android/net/IpMemoryStoreClient.java",
"java/android/net/ipmemorystore/**/*.java",
],
static_libs: [
"ipmemorystore-aidl-interfaces-V3-java",
"networkstack-client",
],
}

View File

@@ -1,9 +0,0 @@
package android.net;
interface IIpMemoryStore {
oneway void storeNetworkAttributes(String l2Key, in android.net.ipmemorystore.NetworkAttributesParcelable attributes, android.net.ipmemorystore.IOnStatusListener listener);
oneway void storeBlob(String l2Key, String clientId, String name, in android.net.ipmemorystore.Blob data, android.net.ipmemorystore.IOnStatusListener listener);
oneway void findL2Key(in android.net.ipmemorystore.NetworkAttributesParcelable attributes, android.net.ipmemorystore.IOnL2KeyResponseListener listener);
oneway void isSameNetwork(String l2Key1, String l2Key2, android.net.ipmemorystore.IOnSameL3NetworkResponseListener listener);
oneway void retrieveNetworkAttributes(String l2Key, android.net.ipmemorystore.IOnNetworkAttributesRetrievedListener listener);
oneway void retrieveBlob(String l2Key, String clientId, String name, android.net.ipmemorystore.IOnBlobRetrievedListener listener);
}

View File

@@ -1,4 +0,0 @@
package android.net;
interface IIpMemoryStoreCallbacks {
oneway void onIpMemoryStoreFetched(in android.net.IIpMemoryStore ipMemoryStore);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
parcelable Blob {
byte[] data;
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnBlobRetrievedListener {
oneway void onBlobRetrieved(in android.net.ipmemorystore.StatusParcelable status, in String l2Key, in String name, in android.net.ipmemorystore.Blob data);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnL2KeyResponseListener {
oneway void onL2KeyResponse(in android.net.ipmemorystore.StatusParcelable status, in String l2Key);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnNetworkAttributesRetrievedListener {
oneway void onNetworkAttributesRetrieved(in android.net.ipmemorystore.StatusParcelable status, in String l2Key, in android.net.ipmemorystore.NetworkAttributesParcelable attributes);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnSameL3NetworkResponseListener {
oneway void onSameL3NetworkResponse(in android.net.ipmemorystore.StatusParcelable status, in android.net.ipmemorystore.SameL3NetworkResponseParcelable response);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnStatusListener {
oneway void onComplete(in android.net.ipmemorystore.StatusParcelable status);
}

View File

@@ -1,8 +0,0 @@
package android.net.ipmemorystore;
parcelable NetworkAttributesParcelable {
byte[] assignedV4Address;
long assignedV4AddressExpiry;
String groupHint;
android.net.ipmemorystore.Blob[] dnsAddresses;
int mtu;
}

View File

@@ -1,6 +0,0 @@
package android.net.ipmemorystore;
parcelable SameL3NetworkResponseParcelable {
String l2Key1;
String l2Key2;
float confidence;
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
parcelable StatusParcelable {
int resultCode;
}

View File

@@ -1,9 +0,0 @@
package android.net;
interface IIpMemoryStore {
oneway void storeNetworkAttributes(String l2Key, in android.net.ipmemorystore.NetworkAttributesParcelable attributes, android.net.ipmemorystore.IOnStatusListener listener);
oneway void storeBlob(String l2Key, String clientId, String name, in android.net.ipmemorystore.Blob data, android.net.ipmemorystore.IOnStatusListener listener);
oneway void findL2Key(in android.net.ipmemorystore.NetworkAttributesParcelable attributes, android.net.ipmemorystore.IOnL2KeyResponseListener listener);
oneway void isSameNetwork(String l2Key1, String l2Key2, android.net.ipmemorystore.IOnSameL3NetworkResponseListener listener);
oneway void retrieveNetworkAttributes(String l2Key, android.net.ipmemorystore.IOnNetworkAttributesRetrievedListener listener);
oneway void retrieveBlob(String l2Key, String clientId, String name, android.net.ipmemorystore.IOnBlobRetrievedListener listener);
}

View File

@@ -1,4 +0,0 @@
package android.net;
interface IIpMemoryStoreCallbacks {
oneway void onIpMemoryStoreFetched(in android.net.IIpMemoryStore ipMemoryStore);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
parcelable Blob {
byte[] data;
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnBlobRetrievedListener {
oneway void onBlobRetrieved(in android.net.ipmemorystore.StatusParcelable status, in String l2Key, in String name, in android.net.ipmemorystore.Blob data);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnL2KeyResponseListener {
oneway void onL2KeyResponse(in android.net.ipmemorystore.StatusParcelable status, in String l2Key);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnNetworkAttributesRetrievedListener {
oneway void onNetworkAttributesRetrieved(in android.net.ipmemorystore.StatusParcelable status, in String l2Key, in android.net.ipmemorystore.NetworkAttributesParcelable attributes);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnSameL3NetworkResponseListener {
oneway void onSameL3NetworkResponse(in android.net.ipmemorystore.StatusParcelable status, in android.net.ipmemorystore.SameL3NetworkResponseParcelable response);
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
interface IOnStatusListener {
oneway void onComplete(in android.net.ipmemorystore.StatusParcelable status);
}

View File

@@ -1,8 +0,0 @@
package android.net.ipmemorystore;
parcelable NetworkAttributesParcelable {
byte[] assignedV4Address;
long assignedV4AddressExpiry;
String groupHint;
android.net.ipmemorystore.Blob[] dnsAddresses;
int mtu;
}

View File

@@ -1,6 +0,0 @@
package android.net.ipmemorystore;
parcelable SameL3NetworkResponseParcelable {
String l2Key1;
String l2Key2;
float confidence;
}

View File

@@ -1,4 +0,0 @@
package android.net.ipmemorystore;
parcelable StatusParcelable {
int resultCode;
}

View File

@@ -1,27 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
interface IIpMemoryStore {
oneway void storeNetworkAttributes(String l2Key, in android.net.ipmemorystore.NetworkAttributesParcelable attributes, android.net.ipmemorystore.IOnStatusListener listener);
oneway void storeBlob(String l2Key, String clientId, String name, in android.net.ipmemorystore.Blob data, android.net.ipmemorystore.IOnStatusListener listener);
oneway void findL2Key(in android.net.ipmemorystore.NetworkAttributesParcelable attributes, android.net.ipmemorystore.IOnL2KeyResponseListener listener);
oneway void isSameNetwork(String l2Key1, String l2Key2, android.net.ipmemorystore.IOnSameL3NetworkResponseListener listener);
oneway void retrieveNetworkAttributes(String l2Key, android.net.ipmemorystore.IOnNetworkAttributesRetrievedListener listener);
oneway void retrieveBlob(String l2Key, String clientId, String name, android.net.ipmemorystore.IOnBlobRetrievedListener listener);
oneway void factoryReset();
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
interface IIpMemoryStoreCallbacks {
oneway void onIpMemoryStoreFetched(in android.net.IIpMemoryStore ipMemoryStore);
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
parcelable Blob {
byte[] data;
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
interface IOnBlobRetrievedListener {
oneway void onBlobRetrieved(in android.net.ipmemorystore.StatusParcelable status, in String l2Key, in String name, in android.net.ipmemorystore.Blob data);
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
interface IOnL2KeyResponseListener {
oneway void onL2KeyResponse(in android.net.ipmemorystore.StatusParcelable status, in String l2Key);
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
interface IOnNetworkAttributesRetrievedListener {
oneway void onNetworkAttributesRetrieved(in android.net.ipmemorystore.StatusParcelable status, in String l2Key, in android.net.ipmemorystore.NetworkAttributesParcelable attributes);
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
interface IOnSameL3NetworkResponseListener {
oneway void onSameL3NetworkResponse(in android.net.ipmemorystore.StatusParcelable status, in android.net.ipmemorystore.SameL3NetworkResponseParcelable response);
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
interface IOnStatusListener {
oneway void onComplete(in android.net.ipmemorystore.StatusParcelable status);
}

View File

@@ -1,25 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
parcelable NetworkAttributesParcelable {
byte[] assignedV4Address;
long assignedV4AddressExpiry;
String groupHint;
android.net.ipmemorystore.Blob[] dnsAddresses;
int mtu;
}

View File

@@ -1,23 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
parcelable SameL3NetworkResponseParcelable {
String l2Key1;
String l2Key2;
float confidence;
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ipmemorystore;
parcelable StatusParcelable {
int resultCode;
}

View File

@@ -1,8 +0,0 @@
package android.net;
parcelable DhcpResultsParcelable {
android.net.StaticIpConfiguration baseConfiguration;
int leaseDuration;
int mtu;
String serverAddress;
String vendorInfo;
}

View File

@@ -1,17 +0,0 @@
package android.net;
interface INetworkMonitor {
oneway void start();
oneway void launchCaptivePortalApp();
oneway void notifyCaptivePortalAppFinished(int response);
oneway void setAcceptPartialConnectivity();
oneway void forceReevaluation(int uid);
oneway void notifyPrivateDnsChanged(in android.net.PrivateDnsConfigParcel config);
oneway void notifyDnsResponse(int returnCode);
oneway void notifyNetworkConnected(in android.net.LinkProperties lp, in android.net.NetworkCapabilities nc);
oneway void notifyNetworkDisconnected();
oneway void notifyLinkPropertiesChanged(in android.net.LinkProperties lp);
oneway void notifyNetworkCapabilitiesChanged(in android.net.NetworkCapabilities nc);
const int NETWORK_TEST_RESULT_VALID = 0;
const int NETWORK_TEST_RESULT_INVALID = 1;
const int NETWORK_TEST_RESULT_PARTIAL_CONNECTIVITY = 2;
}

View File

@@ -1,8 +0,0 @@
package android.net;
interface INetworkMonitorCallbacks {
oneway void onNetworkMonitorCreated(in android.net.INetworkMonitor networkMonitor);
oneway void notifyNetworkTested(int testResult, @nullable String redirectUrl);
oneway void notifyPrivateDnsConfigResolved(in android.net.PrivateDnsConfigParcel config);
oneway void showProvisioningNotification(String action, String packageName);
oneway void hideProvisioningNotification();
}

View File

@@ -1,7 +0,0 @@
package android.net;
interface INetworkStackConnector {
oneway void makeDhcpServer(in String ifName, in android.net.dhcp.DhcpServingParamsParcel params, in android.net.dhcp.IDhcpServerCallbacks cb);
oneway void makeNetworkMonitor(in android.net.Network network, String name, in android.net.INetworkMonitorCallbacks cb);
oneway void makeIpClient(in String ifName, in android.net.ip.IIpClientCallbacks callbacks);
oneway void fetchIpMemoryStore(in android.net.IIpMemoryStoreCallbacks cb);
}

View File

@@ -1,4 +0,0 @@
package android.net;
interface INetworkStackStatusCallback {
oneway void onStatusAvailable(int statusCode);
}

View File

@@ -1,7 +0,0 @@
package android.net;
parcelable InitialConfigurationParcelable {
android.net.LinkAddress[] ipAddresses;
android.net.IpPrefix[] directlyConnectedRoutes;
String[] dnsServers;
String gateway;
}

View File

@@ -1,5 +0,0 @@
package android.net;
parcelable PrivateDnsConfigParcel {
String hostname;
String[] ips;
}

View File

@@ -1,15 +0,0 @@
package android.net;
parcelable ProvisioningConfigurationParcelable {
boolean enableIPv4;
boolean enableIPv6;
boolean usingMultinetworkPolicyTracker;
boolean usingIpReachabilityMonitor;
int requestedPreDhcpActionMs;
android.net.InitialConfigurationParcelable initialConfig;
android.net.StaticIpConfiguration staticIpConfig;
android.net.apf.ApfCapabilities apfCapabilities;
int provisioningTimeoutMs;
int ipv6AddrGenMode;
android.net.Network network;
String displayName;
}

View File

@@ -1,13 +0,0 @@
package android.net;
parcelable TcpKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
int seq;
int ack;
int rcvWnd;
int rcvWndScale;
int tos;
int ttl;
}

View File

@@ -1,11 +0,0 @@
package android.net.dhcp;
parcelable DhcpServingParamsParcel {
int serverAddr;
int serverAddrPrefixLength;
int[] defaultRouters;
int[] dnsServers;
int[] excludedAddrs;
long dhcpLeaseTimeSecs;
int linkMtu;
boolean metered;
}

View File

@@ -1,10 +0,0 @@
package android.net.dhcp;
interface IDhcpServer {
oneway void start(in android.net.INetworkStackStatusCallback cb);
oneway void updateParams(in android.net.dhcp.DhcpServingParamsParcel params, in android.net.INetworkStackStatusCallback cb);
oneway void stop(in android.net.INetworkStackStatusCallback cb);
const int STATUS_UNKNOWN = 0;
const int STATUS_SUCCESS = 1;
const int STATUS_INVALID_ARGUMENT = 2;
const int STATUS_UNKNOWN_ERROR = 3;
}

View File

@@ -1,4 +0,0 @@
package android.net.dhcp;
interface IDhcpServerCallbacks {
oneway void onDhcpServerCreated(int statusCode, in android.net.dhcp.IDhcpServer server);
}

View File

@@ -1,14 +0,0 @@
package android.net.ip;
interface IIpClient {
oneway void completedPreDhcpAction();
oneway void confirmConfiguration();
oneway void readPacketFilterComplete(in byte[] data);
oneway void shutdown();
oneway void startProvisioning(in android.net.ProvisioningConfigurationParcelable req);
oneway void stop();
oneway void setTcpBufferSizes(in String tcpBufferSizes);
oneway void setHttpProxy(in android.net.ProxyInfo proxyInfo);
oneway void setMulticastFilter(boolean enabled);
oneway void addKeepalivePacketFilter(int slot, in android.net.TcpKeepalivePacketDataParcelable pkt);
oneway void removeKeepalivePacketFilter(int slot);
}

View File

@@ -1,16 +0,0 @@
package android.net.ip;
interface IIpClientCallbacks {
oneway void onIpClientCreated(in android.net.ip.IIpClient ipClient);
oneway void onPreDhcpAction();
oneway void onPostDhcpAction();
oneway void onNewDhcpResults(in android.net.DhcpResultsParcelable dhcpResults);
oneway void onProvisioningSuccess(in android.net.LinkProperties newLp);
oneway void onProvisioningFailure(in android.net.LinkProperties newLp);
oneway void onLinkPropertiesChange(in android.net.LinkProperties newLp);
oneway void onReachabilityLost(in String logMsg);
oneway void onQuit();
oneway void installPacketFilter(in byte[] filter);
oneway void startReadPacketFilter();
oneway void setFallbackMulticastFilter(boolean enabled);
oneway void setNeighborDiscoveryOffload(boolean enable);
}

View File

@@ -1,9 +0,0 @@
package android.net;
parcelable DhcpResultsParcelable {
android.net.StaticIpConfiguration baseConfiguration;
int leaseDuration;
int mtu;
String serverAddress;
String vendorInfo;
String serverHostName;
}

View File

@@ -1,24 +0,0 @@
package android.net;
interface INetworkMonitor {
oneway void start();
oneway void launchCaptivePortalApp();
oneway void notifyCaptivePortalAppFinished(int response);
oneway void setAcceptPartialConnectivity();
oneway void forceReevaluation(int uid);
oneway void notifyPrivateDnsChanged(in android.net.PrivateDnsConfigParcel config);
oneway void notifyDnsResponse(int returnCode);
oneway void notifyNetworkConnected(in android.net.LinkProperties lp, in android.net.NetworkCapabilities nc);
oneway void notifyNetworkDisconnected();
oneway void notifyLinkPropertiesChanged(in android.net.LinkProperties lp);
oneway void notifyNetworkCapabilitiesChanged(in android.net.NetworkCapabilities nc);
const int NETWORK_TEST_RESULT_VALID = 0;
const int NETWORK_TEST_RESULT_INVALID = 1;
const int NETWORK_TEST_RESULT_PARTIAL_CONNECTIVITY = 2;
const int NETWORK_VALIDATION_RESULT_VALID = 1;
const int NETWORK_VALIDATION_RESULT_PARTIAL = 2;
const int NETWORK_VALIDATION_PROBE_DNS = 4;
const int NETWORK_VALIDATION_PROBE_HTTP = 8;
const int NETWORK_VALIDATION_PROBE_HTTPS = 16;
const int NETWORK_VALIDATION_PROBE_FALLBACK = 32;
const int NETWORK_VALIDATION_PROBE_PRIVDNS = 64;
}

View File

@@ -1,8 +0,0 @@
package android.net;
interface INetworkMonitorCallbacks {
oneway void onNetworkMonitorCreated(in android.net.INetworkMonitor networkMonitor);
oneway void notifyNetworkTested(int testResult, @nullable String redirectUrl);
oneway void notifyPrivateDnsConfigResolved(in android.net.PrivateDnsConfigParcel config);
oneway void showProvisioningNotification(String action, String packageName);
oneway void hideProvisioningNotification();
}

View File

@@ -1,7 +0,0 @@
package android.net;
interface INetworkStackConnector {
oneway void makeDhcpServer(in String ifName, in android.net.dhcp.DhcpServingParamsParcel params, in android.net.dhcp.IDhcpServerCallbacks cb);
oneway void makeNetworkMonitor(in android.net.Network network, String name, in android.net.INetworkMonitorCallbacks cb);
oneway void makeIpClient(in String ifName, in android.net.ip.IIpClientCallbacks callbacks);
oneway void fetchIpMemoryStore(in android.net.IIpMemoryStoreCallbacks cb);
}

View File

@@ -1,4 +0,0 @@
package android.net;
interface INetworkStackStatusCallback {
oneway void onStatusAvailable(int statusCode);
}

View File

@@ -1,7 +0,0 @@
package android.net;
parcelable InitialConfigurationParcelable {
android.net.LinkAddress[] ipAddresses;
android.net.IpPrefix[] directlyConnectedRoutes;
String[] dnsServers;
String gateway;
}

View File

@@ -1,7 +0,0 @@
package android.net;
parcelable NattKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
}

View File

@@ -1,5 +0,0 @@
package android.net;
parcelable PrivateDnsConfigParcel {
String hostname;
String[] ips;
}

View File

@@ -1,15 +0,0 @@
package android.net;
parcelable ProvisioningConfigurationParcelable {
boolean enableIPv4;
boolean enableIPv6;
boolean usingMultinetworkPolicyTracker;
boolean usingIpReachabilityMonitor;
int requestedPreDhcpActionMs;
android.net.InitialConfigurationParcelable initialConfig;
android.net.StaticIpConfiguration staticIpConfig;
android.net.apf.ApfCapabilities apfCapabilities;
int provisioningTimeoutMs;
int ipv6AddrGenMode;
android.net.Network network;
String displayName;
}

View File

@@ -1,13 +0,0 @@
package android.net;
parcelable TcpKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
int seq;
int ack;
int rcvWnd;
int rcvWndScale;
int tos;
int ttl;
}

View File

@@ -1,11 +0,0 @@
package android.net.dhcp;
parcelable DhcpServingParamsParcel {
int serverAddr;
int serverAddrPrefixLength;
int[] defaultRouters;
int[] dnsServers;
int[] excludedAddrs;
long dhcpLeaseTimeSecs;
int linkMtu;
boolean metered;
}

View File

@@ -1,10 +0,0 @@
package android.net.dhcp;
interface IDhcpServer {
oneway void start(in android.net.INetworkStackStatusCallback cb);
oneway void updateParams(in android.net.dhcp.DhcpServingParamsParcel params, in android.net.INetworkStackStatusCallback cb);
oneway void stop(in android.net.INetworkStackStatusCallback cb);
const int STATUS_UNKNOWN = 0;
const int STATUS_SUCCESS = 1;
const int STATUS_INVALID_ARGUMENT = 2;
const int STATUS_UNKNOWN_ERROR = 3;
}

View File

@@ -1,4 +0,0 @@
package android.net.dhcp;
interface IDhcpServerCallbacks {
oneway void onDhcpServerCreated(int statusCode, in android.net.dhcp.IDhcpServer server);
}

View File

@@ -1,15 +0,0 @@
package android.net.ip;
interface IIpClient {
oneway void completedPreDhcpAction();
oneway void confirmConfiguration();
oneway void readPacketFilterComplete(in byte[] data);
oneway void shutdown();
oneway void startProvisioning(in android.net.ProvisioningConfigurationParcelable req);
oneway void stop();
oneway void setTcpBufferSizes(in String tcpBufferSizes);
oneway void setHttpProxy(in android.net.ProxyInfo proxyInfo);
oneway void setMulticastFilter(boolean enabled);
oneway void addKeepalivePacketFilter(int slot, in android.net.TcpKeepalivePacketDataParcelable pkt);
oneway void removeKeepalivePacketFilter(int slot);
oneway void setL2KeyAndGroupHint(in String l2Key, in String groupHint);
}

View File

@@ -1,16 +0,0 @@
package android.net.ip;
interface IIpClientCallbacks {
oneway void onIpClientCreated(in android.net.ip.IIpClient ipClient);
oneway void onPreDhcpAction();
oneway void onPostDhcpAction();
oneway void onNewDhcpResults(in android.net.DhcpResultsParcelable dhcpResults);
oneway void onProvisioningSuccess(in android.net.LinkProperties newLp);
oneway void onProvisioningFailure(in android.net.LinkProperties newLp);
oneway void onLinkPropertiesChange(in android.net.LinkProperties newLp);
oneway void onReachabilityLost(in String logMsg);
oneway void onQuit();
oneway void installPacketFilter(in byte[] filter);
oneway void startReadPacketFilter();
oneway void setFallbackMulticastFilter(boolean enabled);
oneway void setNeighborDiscoveryOffload(boolean enable);
}

View File

@@ -1,26 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
parcelable DhcpResultsParcelable {
android.net.StaticIpConfiguration baseConfiguration;
int leaseDuration;
int mtu;
String serverAddress;
String vendorInfo;
String serverHostName;
}

View File

@@ -1,41 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
interface INetworkMonitor {
oneway void start();
oneway void launchCaptivePortalApp();
oneway void notifyCaptivePortalAppFinished(int response);
oneway void setAcceptPartialConnectivity();
oneway void forceReevaluation(int uid);
oneway void notifyPrivateDnsChanged(in android.net.PrivateDnsConfigParcel config);
oneway void notifyDnsResponse(int returnCode);
oneway void notifyNetworkConnected(in android.net.LinkProperties lp, in android.net.NetworkCapabilities nc);
oneway void notifyNetworkDisconnected();
oneway void notifyLinkPropertiesChanged(in android.net.LinkProperties lp);
oneway void notifyNetworkCapabilitiesChanged(in android.net.NetworkCapabilities nc);
const int NETWORK_TEST_RESULT_VALID = 0;
const int NETWORK_TEST_RESULT_INVALID = 1;
const int NETWORK_TEST_RESULT_PARTIAL_CONNECTIVITY = 2;
const int NETWORK_VALIDATION_RESULT_VALID = 1;
const int NETWORK_VALIDATION_RESULT_PARTIAL = 2;
const int NETWORK_VALIDATION_PROBE_DNS = 4;
const int NETWORK_VALIDATION_PROBE_HTTP = 8;
const int NETWORK_VALIDATION_PROBE_HTTPS = 16;
const int NETWORK_VALIDATION_PROBE_FALLBACK = 32;
const int NETWORK_VALIDATION_PROBE_PRIVDNS = 64;
}

View File

@@ -1,25 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
interface INetworkMonitorCallbacks {
oneway void onNetworkMonitorCreated(in android.net.INetworkMonitor networkMonitor);
oneway void notifyNetworkTested(int testResult, @nullable String redirectUrl);
oneway void notifyPrivateDnsConfigResolved(in android.net.PrivateDnsConfigParcel config);
oneway void showProvisioningNotification(String action, String packageName);
oneway void hideProvisioningNotification();
}

View File

@@ -1,24 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
interface INetworkStackConnector {
oneway void makeDhcpServer(in String ifName, in android.net.dhcp.DhcpServingParamsParcel params, in android.net.dhcp.IDhcpServerCallbacks cb);
oneway void makeNetworkMonitor(in android.net.Network network, String name, in android.net.INetworkMonitorCallbacks cb);
oneway void makeIpClient(in String ifName, in android.net.ip.IIpClientCallbacks callbacks);
oneway void fetchIpMemoryStore(in android.net.IIpMemoryStoreCallbacks cb);
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
interface INetworkStackStatusCallback {
oneway void onStatusAvailable(int statusCode);
}

View File

@@ -1,24 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
parcelable InitialConfigurationParcelable {
android.net.LinkAddress[] ipAddresses;
android.net.IpPrefix[] directlyConnectedRoutes;
String[] dnsServers;
String gateway;
}

View File

@@ -1,24 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
parcelable NattKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
}

View File

@@ -1,22 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
parcelable PrivateDnsConfigParcel {
String hostname;
String[] ips;
}

View File

@@ -1,32 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
parcelable ProvisioningConfigurationParcelable {
boolean enableIPv4;
boolean enableIPv6;
boolean usingMultinetworkPolicyTracker;
boolean usingIpReachabilityMonitor;
int requestedPreDhcpActionMs;
android.net.InitialConfigurationParcelable initialConfig;
android.net.StaticIpConfiguration staticIpConfig;
android.net.apf.ApfCapabilities apfCapabilities;
int provisioningTimeoutMs;
int ipv6AddrGenMode;
android.net.Network network;
String displayName;
}

View File

@@ -1,30 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net;
parcelable TcpKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
int seq;
int ack;
int rcvWnd;
int rcvWndScale;
int tos;
int ttl;
}

View File

@@ -1,28 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.dhcp;
parcelable DhcpServingParamsParcel {
int serverAddr;
int serverAddrPrefixLength;
int[] defaultRouters;
int[] dnsServers;
int[] excludedAddrs;
long dhcpLeaseTimeSecs;
int linkMtu;
boolean metered;
}

View File

@@ -1,27 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.dhcp;
interface IDhcpServer {
oneway void start(in android.net.INetworkStackStatusCallback cb);
oneway void updateParams(in android.net.dhcp.DhcpServingParamsParcel params, in android.net.INetworkStackStatusCallback cb);
oneway void stop(in android.net.INetworkStackStatusCallback cb);
const int STATUS_UNKNOWN = 0;
const int STATUS_SUCCESS = 1;
const int STATUS_INVALID_ARGUMENT = 2;
const int STATUS_UNKNOWN_ERROR = 3;
}

View File

@@ -1,21 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.dhcp;
interface IDhcpServerCallbacks {
oneway void onDhcpServerCreated(int statusCode, in android.net.dhcp.IDhcpServer server);
}

View File

@@ -1,33 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ip;
interface IIpClient {
oneway void completedPreDhcpAction();
oneway void confirmConfiguration();
oneway void readPacketFilterComplete(in byte[] data);
oneway void shutdown();
oneway void startProvisioning(in android.net.ProvisioningConfigurationParcelable req);
oneway void stop();
oneway void setTcpBufferSizes(in String tcpBufferSizes);
oneway void setHttpProxy(in android.net.ProxyInfo proxyInfo);
oneway void setMulticastFilter(boolean enabled);
oneway void addKeepalivePacketFilter(int slot, in android.net.TcpKeepalivePacketDataParcelable pkt);
oneway void removeKeepalivePacketFilter(int slot);
oneway void setL2KeyAndGroupHint(in String l2Key, in String groupHint);
oneway void addNattKeepalivePacketFilter(int slot, in android.net.NattKeepalivePacketDataParcelable pkt);
}

View File

@@ -1,33 +0,0 @@
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a frozen snapshot of an AIDL interface (or parcelable). Do not
// try to edit this file. It looks like you are doing that because you have
// modified an AIDL interface in a backward-incompatible way, e.g., deleting a
// function from an interface or a field from a parcelable and it broke the
// build. That breakage is intended.
//
// You must not make a backward incompatible changes to the AIDL files built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.net.ip;
interface IIpClientCallbacks {
oneway void onIpClientCreated(in android.net.ip.IIpClient ipClient);
oneway void onPreDhcpAction();
oneway void onPostDhcpAction();
oneway void onNewDhcpResults(in android.net.DhcpResultsParcelable dhcpResults);
oneway void onProvisioningSuccess(in android.net.LinkProperties newLp);
oneway void onProvisioningFailure(in android.net.LinkProperties newLp);
oneway void onLinkPropertiesChange(in android.net.LinkProperties newLp);
oneway void onReachabilityLost(in String logMsg);
oneway void onQuit();
oneway void installPacketFilter(in byte[] filter);
oneway void startReadPacketFilter();
oneway void setFallbackMulticastFilter(boolean enabled);
oneway void setNeighborDiscoveryOffload(boolean enable);
}

View File

@@ -1,28 +0,0 @@
/**
* Copyright (c) 2019, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net;
import android.net.StaticIpConfiguration;
parcelable DhcpResultsParcelable {
StaticIpConfiguration baseConfiguration;
int leaseDuration;
int mtu;
String serverAddress;
String vendorInfo;
String serverHostName;
}

View File

@@ -1,118 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
import android.net.ipmemorystore.Blob;
import android.net.ipmemorystore.NetworkAttributesParcelable;
import android.net.ipmemorystore.IOnBlobRetrievedListener;
import android.net.ipmemorystore.IOnL2KeyResponseListener;
import android.net.ipmemorystore.IOnNetworkAttributesRetrievedListener;
import android.net.ipmemorystore.IOnSameL3NetworkResponseListener;
import android.net.ipmemorystore.IOnStatusListener;
/** {@hide} */
oneway interface IIpMemoryStore {
/**
* Store network attributes for a given L2 key.
* If L2Key is null, choose automatically from the attributes ; passing null is equivalent to
* calling findL2Key with the attributes and storing in the returned value.
*
* @param l2Key The L2 key for the L2 network. Clients that don't know or care about the L2
* key and only care about grouping can pass a unique ID here like the ones
* generated by {@code java.util.UUID.randomUUID()}, but keep in mind the low
* relevance of such a network will lead to it being evicted soon if it's not
* refreshed. Use findL2Key to try and find a similar L2Key to these attributes.
* @param attributes The attributes for this network.
* @param listener A listener that will be invoked to inform of the completion of this call,
* or null if the client is not interested in learning about success/failure.
* @return (through the listener) The L2 key. This is useful if the L2 key was not specified.
* If the call failed, the L2 key will be null.
*/
void storeNetworkAttributes(String l2Key, in NetworkAttributesParcelable attributes,
IOnStatusListener listener);
/**
* Store a binary blob associated with an L2 key and a name.
*
* @param l2Key The L2 key for this network.
* @param clientId The ID of the client.
* @param name The name of this data.
* @param data The data to store.
* @param listener A listener to inform of the completion of this call, or null if the client
* is not interested in learning about success/failure.
* @return (through the listener) A status to indicate success or failure.
*/
void storeBlob(String l2Key, String clientId, String name, in Blob data,
IOnStatusListener listener);
/**
* Returns the best L2 key associated with the attributes.
*
* This will find a record that would be in the same group as the passed attributes. This is
* useful to choose the key for storing a sample or private data when the L2 key is not known.
* If multiple records are group-close to these attributes, the closest match is returned.
* If multiple records have the same closeness, the one with the smaller (unicode codepoint
* order) L2 key is returned.
* If no record matches these attributes, null is returned.
*
* @param attributes The attributes of the network to find.
* @param listener The listener that will be invoked to return the answer.
* @return (through the listener) The L2 key if one matched, or null.
*/
void findL2Key(in NetworkAttributesParcelable attributes, IOnL2KeyResponseListener listener);
/**
* Returns whether, to the best of the store's ability to tell, the two specified L2 keys point
* to the same L3 network. Group-closeness is used to determine this.
*
* @param l2Key1 The key for the first network.
* @param l2Key2 The key for the second network.
* @param listener The listener that will be invoked to return the answer.
* @return (through the listener) A SameL3NetworkResponse containing the answer and confidence.
*/
void isSameNetwork(String l2Key1, String l2Key2, IOnSameL3NetworkResponseListener listener);
/**
* Retrieve the network attributes for a key.
* If no record is present for this key, this will return null attributes.
*
* @param l2Key The key of the network to query.
* @param listener The listener that will be invoked to return the answer.
* @return (through the listener) The network attributes and the L2 key associated with
* the query.
*/
void retrieveNetworkAttributes(String l2Key, IOnNetworkAttributesRetrievedListener listener);
/**
* Retrieve previously stored private data.
* If no data was stored for this L2 key and name this will return null.
*
* @param l2Key The L2 key.
* @param clientId The id of the client that stored this data.
* @param name The name of the data.
* @param listener The listener that will be invoked to return the answer.
* @return (through the listener) The private data (or null), with the L2 key
* and the name of the data associated with the query.
*/
void retrieveBlob(String l2Key, String clientId, String name,
IOnBlobRetrievedListener listener);
/**
* Delete all data because a factory reset operation is in progress.
*/
void factoryReset();
}

View File

@@ -1,24 +0,0 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
import android.net.IIpMemoryStore;
/** {@hide} */
oneway interface IIpMemoryStoreCallbacks {
void onIpMemoryStoreFetched(in IIpMemoryStore ipMemoryStore);
}

View File

@@ -1,68 +0,0 @@
/**
* Copyright (c) 2018, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net;
import android.net.LinkProperties;
import android.net.NetworkCapabilities;
import android.net.PrivateDnsConfigParcel;
/** @hide */
oneway interface INetworkMonitor {
// After a network has been tested this result can be sent with EVENT_NETWORK_TESTED.
// The network should be used as a default internet connection. It was found to be:
// 1. a functioning network providing internet access, or
// 2. a captive portal and the user decided to use it as is.
const int NETWORK_TEST_RESULT_VALID = 0;
// After a network has been tested this result can be sent with EVENT_NETWORK_TESTED.
// The network should not be used as a default internet connection. It was found to be:
// 1. a captive portal and the user is prompted to sign-in, or
// 2. a captive portal and the user did not want to use it, or
// 3. a broken network (e.g. DNS failed, connect failed, HTTP request failed).
const int NETWORK_TEST_RESULT_INVALID = 1;
// After a network has been tested, this result can be sent with EVENT_NETWORK_TESTED.
// The network may be used as a default internet connection, but it was found to be a partial
// connectivity network which can get the pass result for http probe but get the failed result
// for https probe.
const int NETWORK_TEST_RESULT_PARTIAL_CONNECTIVITY = 2;
// Network validation flags indicate probe result and types. If no NETWORK_VALIDATION_RESULT_*
// are set, then it's equal to NETWORK_TEST_RESULT_INVALID. If NETWORK_VALIDATION_RESULT_VALID
// is set, then the network validates and equal to NETWORK_TEST_RESULT_VALID. If
// NETWORK_VALIDATION_RESULT_PARTIAL is set, then the network has partial connectivity which
// is equal to NETWORK_TEST_RESULT_PARTIAL_CONNECTIVITY. NETWORK_VALIDATION_PROBE_* is set
// when the specific probe result of the network is resolved.
const int NETWORK_VALIDATION_RESULT_VALID = 0x01;
const int NETWORK_VALIDATION_RESULT_PARTIAL = 0x02;
const int NETWORK_VALIDATION_PROBE_DNS = 0x04;
const int NETWORK_VALIDATION_PROBE_HTTP = 0x08;
const int NETWORK_VALIDATION_PROBE_HTTPS = 0x10;
const int NETWORK_VALIDATION_PROBE_FALLBACK = 0x20;
const int NETWORK_VALIDATION_PROBE_PRIVDNS = 0x40;
void start();
void launchCaptivePortalApp();
void notifyCaptivePortalAppFinished(int response);
void setAcceptPartialConnectivity();
void forceReevaluation(int uid);
void notifyPrivateDnsChanged(in PrivateDnsConfigParcel config);
void notifyDnsResponse(int returnCode);
void notifyNetworkConnected(in LinkProperties lp, in NetworkCapabilities nc);
void notifyNetworkDisconnected();
void notifyLinkPropertiesChanged(in LinkProperties lp);
void notifyNetworkCapabilitiesChanged(in NetworkCapabilities nc);
}

View File

@@ -1,29 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
import android.net.INetworkMonitor;
import android.net.PrivateDnsConfigParcel;
/** @hide */
oneway interface INetworkMonitorCallbacks {
void onNetworkMonitorCreated(in INetworkMonitor networkMonitor);
void notifyNetworkTested(int testResult, @nullable String redirectUrl);
void notifyPrivateDnsConfigResolved(in PrivateDnsConfigParcel config);
void showProvisioningNotification(String action, String packageName);
void hideProvisioningNotification();
}

View File

@@ -1,32 +0,0 @@
/**
* Copyright (c) 2018, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net;
import android.net.IIpMemoryStoreCallbacks;
import android.net.INetworkMonitorCallbacks;
import android.net.Network;
import android.net.dhcp.DhcpServingParamsParcel;
import android.net.dhcp.IDhcpServerCallbacks;
import android.net.ip.IIpClientCallbacks;
/** @hide */
oneway interface INetworkStackConnector {
void makeDhcpServer(in String ifName, in DhcpServingParamsParcel params,
in IDhcpServerCallbacks cb);
void makeNetworkMonitor(in Network network, String name, in INetworkMonitorCallbacks cb);
void makeIpClient(in String ifName, in IIpClientCallbacks callbacks);
void fetchIpMemoryStore(in IIpMemoryStoreCallbacks cb);
}

View File

@@ -1,22 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
/** @hide */
oneway interface INetworkStackStatusCallback {
void onStatusAvailable(int statusCode);
}

View File

@@ -1,27 +0,0 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
import android.net.IpPrefix;
import android.net.LinkAddress;
parcelable InitialConfigurationParcelable {
LinkAddress[] ipAddresses;
IpPrefix[] directlyConnectedRoutes;
String[] dnsServers;
String gateway;
}

View File

@@ -1,227 +0,0 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
import android.annotation.NonNull;
import android.annotation.Nullable;
import android.content.Context;
import android.net.ipmemorystore.Blob;
import android.net.ipmemorystore.NetworkAttributes;
import android.net.ipmemorystore.OnBlobRetrievedListener;
import android.net.ipmemorystore.OnL2KeyResponseListener;
import android.net.ipmemorystore.OnNetworkAttributesRetrievedListener;
import android.net.ipmemorystore.OnSameL3NetworkResponseListener;
import android.net.ipmemorystore.OnStatusListener;
import android.net.ipmemorystore.Status;
import android.os.RemoteException;
import android.util.Log;
import java.util.concurrent.ExecutionException;
import java.util.function.Consumer;
/**
* service used to communicate with the ip memory store service in network stack,
* which is running in a separate module.
* @hide
*/
public abstract class IpMemoryStoreClient {
private static final String TAG = IpMemoryStoreClient.class.getSimpleName();
private final Context mContext;
public IpMemoryStoreClient(@NonNull final Context context) {
if (context == null) throw new IllegalArgumentException("missing context");
mContext = context;
}
protected abstract void runWhenServiceReady(Consumer<IIpMemoryStore> cb)
throws ExecutionException;
@FunctionalInterface
private interface ThrowingRunnable {
void run() throws RemoteException;
}
private void ignoringRemoteException(ThrowingRunnable r) {
ignoringRemoteException("Failed to execute remote procedure call", r);
}
private void ignoringRemoteException(String message, ThrowingRunnable r) {
try {
r.run();
} catch (RemoteException e) {
Log.e(TAG, message, e);
}
}
/**
* Store network attributes for a given L2 key.
* If L2Key is null, choose automatically from the attributes ; passing null is equivalent to
* calling findL2Key with the attributes and storing in the returned value.
*
* @param l2Key The L2 key for the L2 network. Clients that don't know or care about the L2
* key and only care about grouping can pass a unique ID here like the ones
* generated by {@code java.util.UUID.randomUUID()}, but keep in mind the low
* relevance of such a network will lead to it being evicted soon if it's not
* refreshed. Use findL2Key to try and find a similar L2Key to these attributes.
* @param attributes The attributes for this network.
* @param listener A listener that will be invoked to inform of the completion of this call,
* or null if the client is not interested in learning about success/failure.
* Through the listener, returns the L2 key. This is useful if the L2 key was not specified.
* If the call failed, the L2 key will be null.
*/
public void storeNetworkAttributes(@NonNull final String l2Key,
@NonNull final NetworkAttributes attributes,
@Nullable final OnStatusListener listener) {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.storeNetworkAttributes(l2Key, attributes.toParcelable(),
OnStatusListener.toAIDL(listener))));
} catch (ExecutionException m) {
ignoringRemoteException("Error storing network attributes",
() -> listener.onComplete(new Status(Status.ERROR_UNKNOWN)));
}
}
/**
* Store a binary blob associated with an L2 key and a name.
*
* @param l2Key The L2 key for this network.
* @param clientId The ID of the client.
* @param name The name of this data.
* @param data The data to store.
* @param listener A listener to inform of the completion of this call, or null if the client
* is not interested in learning about success/failure.
* Through the listener, returns a status to indicate success or failure.
*/
public void storeBlob(@NonNull final String l2Key, @NonNull final String clientId,
@NonNull final String name, @NonNull final Blob data,
@Nullable final OnStatusListener listener) {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.storeBlob(l2Key, clientId, name, data,
OnStatusListener.toAIDL(listener))));
} catch (ExecutionException m) {
ignoringRemoteException("Error storing blob",
() -> listener.onComplete(new Status(Status.ERROR_UNKNOWN)));
}
}
/**
* Returns the best L2 key associated with the attributes.
*
* This will find a record that would be in the same group as the passed attributes. This is
* useful to choose the key for storing a sample or private data when the L2 key is not known.
* If multiple records are group-close to these attributes, the closest match is returned.
* If multiple records have the same closeness, the one with the smaller (unicode codepoint
* order) L2 key is returned.
* If no record matches these attributes, null is returned.
*
* @param attributes The attributes of the network to find.
* @param listener The listener that will be invoked to return the answer.
* Through the listener, returns the L2 key if one matched, or null.
*/
public void findL2Key(@NonNull final NetworkAttributes attributes,
@NonNull final OnL2KeyResponseListener listener) {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.findL2Key(attributes.toParcelable(),
OnL2KeyResponseListener.toAIDL(listener))));
} catch (ExecutionException m) {
ignoringRemoteException("Error finding L2 Key",
() -> listener.onL2KeyResponse(new Status(Status.ERROR_UNKNOWN), null));
}
}
/**
* Returns whether, to the best of the store's ability to tell, the two specified L2 keys point
* to the same L3 network. Group-closeness is used to determine this.
*
* @param l2Key1 The key for the first network.
* @param l2Key2 The key for the second network.
* @param listener The listener that will be invoked to return the answer.
* Through the listener, a SameL3NetworkResponse containing the answer and confidence.
*/
public void isSameNetwork(@NonNull final String l2Key1, @NonNull final String l2Key2,
@NonNull final OnSameL3NetworkResponseListener listener) {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.isSameNetwork(l2Key1, l2Key2,
OnSameL3NetworkResponseListener.toAIDL(listener))));
} catch (ExecutionException m) {
ignoringRemoteException("Error checking for network sameness",
() -> listener.onSameL3NetworkResponse(new Status(Status.ERROR_UNKNOWN), null));
}
}
/**
* Retrieve the network attributes for a key.
* If no record is present for this key, this will return null attributes.
*
* @param l2Key The key of the network to query.
* @param listener The listener that will be invoked to return the answer.
* Through the listener, returns the network attributes and the L2 key associated with
* the query.
*/
public void retrieveNetworkAttributes(@NonNull final String l2Key,
@NonNull final OnNetworkAttributesRetrievedListener listener) {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.retrieveNetworkAttributes(l2Key,
OnNetworkAttributesRetrievedListener.toAIDL(listener))));
} catch (ExecutionException m) {
ignoringRemoteException("Error retrieving network attributes",
() -> listener.onNetworkAttributesRetrieved(new Status(Status.ERROR_UNKNOWN),
null, null));
}
}
/**
* Retrieve previously stored private data.
* If no data was stored for this L2 key and name this will return null.
*
* @param l2Key The L2 key.
* @param clientId The id of the client that stored this data.
* @param name The name of the data.
* @param listener The listener that will be invoked to return the answer.
* Through the listener, returns the private data (or null), with the L2 key
* and the name of the data associated with the query.
*/
public void retrieveBlob(@NonNull final String l2Key, @NonNull final String clientId,
@NonNull final String name, @NonNull final OnBlobRetrievedListener listener) {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.retrieveBlob(l2Key, clientId, name,
OnBlobRetrievedListener.toAIDL(listener))));
} catch (ExecutionException m) {
ignoringRemoteException("Error retrieving blob",
() -> listener.onBlobRetrieved(new Status(Status.ERROR_UNKNOWN),
null, null, null));
}
}
/**
* Wipe the data in the database upon network factory reset.
*/
public void factoryReset() {
try {
runWhenServiceReady(service -> ignoringRemoteException(
() -> service.factoryReset()));
} catch (ExecutionException m) {
Log.e(TAG, "Error executing factory reset", m);
}
}
}

View File

@@ -1,25 +0,0 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
parcelable NattKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
}

View File

@@ -1,22 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
parcelable PrivateDnsConfigParcel {
String hostname;
String[] ips;
}

View File

@@ -1,38 +0,0 @@
/*
**
** Copyright (C) 2019 The Android Open Source Project
**
** Licensed under the Apache License, Version 2.0 (the "License");
** you may not use this file except in compliance with the License.
** You may obtain a copy of the License at
**
** http://www.apache.org/licenses/LICENSE-2.0
**
** Unless required by applicable law or agreed to in writing, software
** distributed under the License is distributed on an "AS IS" BASIS,
** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
** See the License for the specific language governing permissions and
** limitations under the License.
*/
package android.net;
import android.net.InitialConfigurationParcelable;
import android.net.Network;
import android.net.StaticIpConfiguration;
import android.net.apf.ApfCapabilities;
parcelable ProvisioningConfigurationParcelable {
boolean enableIPv4;
boolean enableIPv6;
boolean usingMultinetworkPolicyTracker;
boolean usingIpReachabilityMonitor;
int requestedPreDhcpActionMs;
InitialConfigurationParcelable initialConfig;
StaticIpConfiguration staticIpConfig;
ApfCapabilities apfCapabilities;
int provisioningTimeoutMs;
int ipv6AddrGenMode;
Network network;
String displayName;
}

View File

@@ -1,30 +0,0 @@
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net;
parcelable TcpKeepalivePacketDataParcelable {
byte[] srcAddress;
int srcPort;
byte[] dstAddress;
int dstPort;
int seq;
int ack;
int rcvWnd;
int rcvWndScale;
int tos;
int ttl;
}

View File

@@ -1,30 +0,0 @@
/**
*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net.dhcp;
parcelable DhcpServingParamsParcel {
int serverAddr;
int serverAddrPrefixLength;
int[] defaultRouters;
int[] dnsServers;
int[] excludedAddrs;
long dhcpLeaseTimeSecs;
int linkMtu;
boolean metered;
}

View File

@@ -1,32 +0,0 @@
/**
* Copyright (c) 2018, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net.dhcp;
import android.net.INetworkStackStatusCallback;
import android.net.dhcp.DhcpServingParamsParcel;
/** @hide */
oneway interface IDhcpServer {
const int STATUS_UNKNOWN = 0;
const int STATUS_SUCCESS = 1;
const int STATUS_INVALID_ARGUMENT = 2;
const int STATUS_UNKNOWN_ERROR = 3;
void start(in INetworkStackStatusCallback cb);
void updateParams(in DhcpServingParamsParcel params, in INetworkStackStatusCallback cb);
void stop(in INetworkStackStatusCallback cb);
}

View File

@@ -1,24 +0,0 @@
/**
* Copyright (c) 2018, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net.dhcp;
import android.net.dhcp.IDhcpServer;
/** @hide */
oneway interface IDhcpServerCallbacks {
void onDhcpServerCreated(int statusCode, in IDhcpServer server);
}

View File

@@ -1,38 +0,0 @@
/**
* Copyright (c) 2019, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net.ip;
import android.net.ProxyInfo;
import android.net.ProvisioningConfigurationParcelable;
import android.net.NattKeepalivePacketDataParcelable;
import android.net.TcpKeepalivePacketDataParcelable;
/** @hide */
oneway interface IIpClient {
void completedPreDhcpAction();
void confirmConfiguration();
void readPacketFilterComplete(in byte[] data);
void shutdown();
void startProvisioning(in ProvisioningConfigurationParcelable req);
void stop();
void setTcpBufferSizes(in String tcpBufferSizes);
void setHttpProxy(in ProxyInfo proxyInfo);
void setMulticastFilter(boolean enabled);
void addKeepalivePacketFilter(int slot, in TcpKeepalivePacketDataParcelable pkt);
void removeKeepalivePacketFilter(int slot);
void setL2KeyAndGroupHint(in String l2Key, in String groupHint);
void addNattKeepalivePacketFilter(int slot, in NattKeepalivePacketDataParcelable pkt);
}

View File

@@ -1,66 +0,0 @@
/**
* Copyright (c) 2019, The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing perNmissions and
* limitations under the License.
*/
package android.net.ip;
import android.net.LinkProperties;
import android.net.ip.IIpClient;
import android.net.DhcpResultsParcelable;
/** @hide */
oneway interface IIpClientCallbacks {
void onIpClientCreated(in IIpClient ipClient);
void onPreDhcpAction();
void onPostDhcpAction();
// This is purely advisory and not an indication of provisioning
// success or failure. This is only here for callers that want to
// expose DHCPv4 results to other APIs (e.g., WifiInfo#setInetAddress).
// DHCPv4 or static IPv4 configuration failure or success can be
// determined by whether or not the passed-in DhcpResults object is
// null or not.
void onNewDhcpResults(in DhcpResultsParcelable dhcpResults);
void onProvisioningSuccess(in LinkProperties newLp);
void onProvisioningFailure(in LinkProperties newLp);
// Invoked on LinkProperties changes.
void onLinkPropertiesChange(in LinkProperties newLp);
// Called when the internal IpReachabilityMonitor (if enabled) has
// detected the loss of a critical number of required neighbors.
void onReachabilityLost(in String logMsg);
// Called when the IpClient state machine terminates.
void onQuit();
// Install an APF program to filter incoming packets.
void installPacketFilter(in byte[] filter);
// Asynchronously read back the APF program & data buffer from the wifi driver.
// Due to Wifi HAL limitations, the current implementation only supports dumping the entire
// buffer. In response to this request, the driver returns the data buffer asynchronously
// by sending an IpClient#EVENT_READ_PACKET_FILTER_COMPLETE message.
void startReadPacketFilter();
// If multicast filtering cannot be accomplished with APF, this function will be called to
// actuate multicast filtering using another means.
void setFallbackMulticastFilter(boolean enabled);
// Enabled/disable Neighbor Discover offload functionality. This is
// called, for example, whenever 464xlat is being started or stopped.
void setNeighborDiscoveryOffload(boolean enable);
}

View File

@@ -1,26 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net.ipmemorystore;
/**
* A blob of data opaque to the memory store. The client mutates this at its own risk,
* and it is strongly suggested to never do it at all and treat this as immutable.
* {@hide}
*/
parcelable Blob {
byte[] data;
}

View File

@@ -1,30 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net.ipmemorystore;
import android.net.ipmemorystore.Blob;
import android.net.ipmemorystore.StatusParcelable;
/** {@hide} */
oneway interface IOnBlobRetrievedListener {
/**
* Private data was retrieved for the L2 key and name specified.
* Note this does not return the client ID, as clients are expected to only ever use one ID.
*/
void onBlobRetrieved(in StatusParcelable status, in String l2Key, in String name,
in Blob data);
}

View File

@@ -1,27 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net.ipmemorystore;
import android.net.ipmemorystore.StatusParcelable;
/** {@hide} */
oneway interface IOnL2KeyResponseListener {
/**
* The operation completed with the specified L2 key.
*/
void onL2KeyResponse(in StatusParcelable status, in String l2Key);
}

View File

@@ -1,30 +0,0 @@
/*
* Copyright (C) 2018 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package android.net.ipmemorystore;
import android.net.ipmemorystore.NetworkAttributesParcelable;
import android.net.ipmemorystore.StatusParcelable;
/** {@hide} */
oneway interface IOnNetworkAttributesRetrievedListener {
/**
* Network attributes were fetched for the specified L2 key. While the L2 key will never
* be null, the attributes may be if no data is stored about this L2 key.
*/
void onNetworkAttributesRetrieved(in StatusParcelable status, in String l2Key,
in NetworkAttributesParcelable attributes);
}

Some files were not shown because too many files have changed in this diff Show More