Commit Graph

4718 Commits

Author SHA1 Message Date
Cody Kesting
7d2cbc1253 Merge "Fix javadoc build break s/line/link/"
am: 5cd89ebb01

Change-Id: Iba1f8ec62784f68bc415690ccf5966445c9b3542
2020-01-24 10:55:47 -08:00
Cody Kesting
5cd89ebb01 Merge "Fix javadoc build break s/line/link/" 2020-01-24 18:37:51 +00:00
Qingxi Li
23f27778e3 Merge "Add API for apps to check if they are the network owner"
am: e021269f8d

Change-Id: I1316c7fccd9b7a35ff6d8a79a8afa13644d9ab54
2020-01-24 10:24:12 -08:00
Qingxi Li
e021269f8d Merge "Add API for apps to check if they are the network owner" 2020-01-24 18:12:52 +00:00
Nathan Harold
ed13bd68c7 Fix javadoc build break s/line/link/
Bug: 148248781
Test: compilation
Change-Id: I9df208a9b063b71b2f6cc3099005d1ab38044cd2
Merged-in: I9df208a9b063b71b2f6cc3099005d1ab38044cd2
2020-01-24 09:43:03 -08:00
Qingxi Li
7cf06627df Add API for apps to check if they are the network owner
This CL extends NetworkCapabilities#mEstablishingVpnAppUid
to the network owner app UID and introduces a new public API
to get this owner app's UID.

Bug: 142072839
Test: atest FrameworksNetTests
Change-Id: Id83cdea62b89b586aff74e51e3fee60e53d37d4c
2020-01-24 17:28:23 +00:00
Automerger Merge Worker
fc04c3840f Merge "Add AIDL for registering ConnectivityDiagnosticCallbacks." am: 5b8737d5d2
Change-Id: I5e53fec27728a65e05c7fdf7501dee1052c52e78
2020-01-24 16:39:47 +00:00
Automerger Merge Worker
bfc434f9d2 Merge "Define ConnectivityDiagnosticsCallback IBinder impl." am: 7975dd5796
Change-Id: I1d60026a7b31af2bc329187685780744c20d7c8c
2020-01-24 16:39:32 +00:00
Automerger Merge Worker
a70650dd73 Merge "Define IConnectivityDiagnosticsCallback aidl." am: 5f0ff62c75
Change-Id: I113ac797db256699e7e3c8fa89b4230964df08d0
2020-01-24 16:39:18 +00:00
Automerger Merge Worker
d4f206ce74 Allows the caller to specify configuration by TetheringRequest am: 0688917e74
Change-Id: I2595221b08eb389dcbe8643f3839707a15bc6ac0
2020-01-24 16:38:45 +00:00
Automerger Merge Worker
47eb5521e8 Make TetheringManager to system API am: 75b6d7b8ae
Change-Id: I9660401878cdbc2feedc7e950f4f02538ca070eb
2020-01-24 16:38:38 +00:00
Cody Kesting
5b8737d5d2 Merge "Add AIDL for registering ConnectivityDiagnosticCallbacks." 2020-01-24 16:38:22 +00:00
Cody Kesting
7975dd5796 Merge "Define ConnectivityDiagnosticsCallback IBinder impl." 2020-01-24 16:38:08 +00:00
Cody Kesting
5f0ff62c75 Merge "Define IConnectivityDiagnosticsCallback aidl." 2020-01-24 16:37:55 +00:00
Lorenzo Colitti
2458be40f4 Merge changes I7065d081,Ic7c3a331,Ia432057b
* changes:
  Add API for tethering clients change
  Allows the caller to specify configuration by TetheringRequest
  Make TetheringManager to system API
2020-01-24 16:23:18 +00:00
markchien
0688917e74 Allows the caller to specify configuration by TetheringRequest
This is initial work to allow caller to pass their prefered
configuration to start tethering. Caller may able to specify the
downstream interface ipv4 address with dhcp server disabled for
static IP configuration, or able to exempt entitlement check if
they have permission in follow up CL.

Bug: 141256482
Test: -atest TetheringTest
      -ON/OFF wifi tethering

Change-Id: Ic7c3a33195bbd7e72f9b8e73fa148be476b87bf3
Merged-In: Ic7c3a33195bbd7e72f9b8e73fa148be476b87bf3
2020-01-24 23:39:50 +09:00
markchien
75b6d7b8ae Make TetheringManager to system API
Also deprecated tethering APIs in ConnectivityManager.
Will have follow up change to remove @hide tethering function in
ConnectivityManager.

Bug: 145093446
Bug: 148038547
Test: -build, flash, boot
      -atest TetheringTests

Change-Id: Ia432057bf9056727c4a0ca97d160a49274d33581
Merged-In: Ia432057bf9056727c4a0ca97d160a49274d33581
2020-01-24 23:39:49 +09:00
Cody Kesting
5aadb8b137 Add AIDL for registering ConnectivityDiagnosticCallbacks.
ConnectivityService needs to allow for registering and unregistering
ConnectivityDiagnosticsCallbacks as part of ConnectivityDiagnostics API.
These methods will be used by ConnectivityDiagnosticsManager so that
privileged applications can receive notifications on network events by
the system.

Bug: 146444622
Test: compiles
Change-Id: Id00b30af5692db5eef47d0d948897148578d3b32
2020-01-23 11:30:04 -08:00
Cody Kesting
8a5f7c9e8a Define ConnectivityDiagnosticsCallback IBinder impl.
An IBinder implementation of the ConnectivityDiagnosticsCallback AIDL is
needed so that apps can receive notfications with their registered
callbacks for callbacks coming from ConnectivityService.

Bug: 143187964
Bug: 147848028
Test: compiles
Test: atest FrameworksNetTests
Change-Id: Ie62678f794d81e1edee68977ec684a911b5070b7
2020-01-23 11:30:04 -08:00
Cody Kesting
91b9d55cee Define IConnectivityDiagnosticsCallback aidl.
IConnectivityDiagnosticsCallback is defined for making Binder calls out
of ConnectivityService to client implementations of
ConnectivityDiagnosticsCallback.

Bug: 143187964
Test: compiles
Change-Id: I68dd1afddaed21528a60c2b6f0add34d0bec8242
2020-01-23 11:30:03 -08:00
Cody Kesting
a549738ce5 Merge "Add list of Administrator UIDs to NetworkCapabilities."
am: 38812f345c

Change-Id: I7e5d0950ba99419d83fed6922a8f29aa530d4b00
2020-01-23 10:18:02 -08:00
Cody Kesting
38812f345c Merge "Add list of Administrator UIDs to NetworkCapabilities." 2020-01-23 17:52:58 +00:00
Nathan Harold
ae31ae6ae4 Merge "Define Bundle keys for ConnectivityDiagnostics."
am: 26216dbc0f

Change-Id: I2a5ac28aea190d06dc2e7e6f8bb9950e0a18e3f7
2020-01-23 08:43:27 -08:00
Nathan Harold
26216dbc0f Merge "Define Bundle keys for ConnectivityDiagnostics." 2020-01-23 16:34:16 +00:00
Cody Kesting
c14f453332 Define Bundle keys for ConnectivityDiagnostics.
ConnectivityDiagnosticsManager defines several callbacks that can be
invoked for registered ConnectivityDiagnosticsCallback instances.
onConnectivityReport and onDataStallSuspected include ConnectivityReport
and DataStallReport, respectively, both of which contain a
PersistableBundle to be used for passing information from the
NetworkStack module to the registered callback. When values will be
consistently passed inside these bundles, their keys are defined inside
ConnectivityReport and DataStallReport.

Bug: 147249364
Test: compiles
Test: atest FrameworksNetTests
Change-Id: Icc6bd4337865692b6ca7c18eacabff59ba3a5bb9
2020-01-23 00:49:17 -08:00
Cody Kesting
201fc13e0c Add list of Administrator UIDs to NetworkCapabilities.
Adds a list of administrator UIDs to NetworkCapabilties. The carrier
privilege permission model allows multiple uids to be granted
network-management privileges via certificates stored on a SIM card or
in CarrierConfigManager. The current NetworkCapabilities only allows a
single uid to be stored to track the owner of the network - this change
remedies that discrepancy.

Bug: 147903575
Test: atest FrameworksNetTests
Change-Id: I3169d31e0270c976a720e80363cb268cbafd0455
2020-01-22 23:59:56 -08:00
Cody Kesting
70d4d6df7f Merge "Fix generic inferred type argument."
am: a538107ad1

Change-Id: I5ac5579440d309c583debe5ce876721a84460c84
2020-01-22 22:45:49 -08:00
Treehugger Robot
a538107ad1 Merge "Fix generic inferred type argument." 2020-01-23 06:39:57 +00:00
Benedict Wong
1ebbd0bb6b Merge changes from topic "add-ikev2-vpn-types"
am: adb79e3b39

Change-Id: I205121bbd8ef8adbe5e7a5ea1c57bbcac0efae0e
2020-01-22 22:09:41 -08:00
Cody Kesting
ef028219c9 Fix generic inferred type argument.
Test: compiles.
Test: atest FrameworksNetTests
Change-Id: I0dffb3f44fb465ac8bae3c41f26176e86f65e825
2020-01-22 20:26:08 -08:00
Benedict Wong
50b444359e Add VpnManger API surface
This change adds the VpnManager, which will be used by apps to install
profiles for all platform VPN types (currently only IKEv2).

Bug: 143325939
Test: Compiles, FrameworksNetTests passing.
Change-Id: I57f854d0a5b18358f3541c24ca0cd8aed03fd7a1
2020-01-22 19:24:24 -08:00
Benedict Wong
feb69c13ef Add Ikev2VpnProfile as public API
This change adds configuration classes for Platform VPNs, with the
extensibility for further platform VPNs to be added in future.

Profile validity is checked upon construction, and upon changing
conversion from VpnProfile instances. Internal storage and method calls
all use VpnProfiles to allow for reuse of existing infrastructure.
However, when Platform VPN implementations are started, the internal
VpnProfile will be converted back into the respective
PlatformVpnProfile for validity checking.

Bug: 143325939
Test: Compiles, FrameworksNetTests passing.
Change-Id: I3c375fb08c132fc062e893c375f5c36460122162
2020-01-22 19:23:01 -08:00
Cody Kesting
45e0caf5dc Merge changes from topic "connectivity-diagnostics-system-server"
am: 9cd249c11a

Change-Id: I48a9f1f734b5e2dd4f7ed91c052cec5c8c62c076
2020-01-22 19:10:05 -08:00
Nathan Harold
fa25f2f38c Merge "Remove StringNetworkSpecifier"
am: bdbc3e7e4e

Change-Id: If2b9e1ef7341b517cb0090ba0ff882b1a6305ed4
2020-01-22 19:09:13 -08:00
Cody Kesting
9cd249c11a Merge changes from topic "connectivity-diagnostics-system-server"
* changes:
  Add ConnectivityDiagnosticsManager to System Server.
  Make DataStallReport Parcelable.
  Make ConnectivityReport Parcelable.
2020-01-23 01:56:33 +00:00
Nathan Harold
bdbc3e7e4e Merge "Remove StringNetworkSpecifier" 2020-01-23 01:08:33 +00:00
Remi NGUYEN VAN
f3011f77d1 Merge "Add API for CaptivePortalData"
am: 144519f45d

Change-Id: Iaf58a9dbba5fd5fbe45ec4d795585efe9e3a9e2a
2020-01-22 08:05:11 -08:00
Remi NGUYEN VAN
144519f45d Merge "Add API for CaptivePortalData" 2020-01-22 15:55:17 +00:00
Remi NGUYEN VAN
3a8c533d65 Merge "Add NetworkCapabilities#getSSID to SystemApi"
am: 385afc999e

Change-Id: I56b30b2719d30660e2efb32a01ab0ce4f7b30236
2020-01-22 07:30:49 -08:00
Treehugger Robot
385afc999e Merge "Add NetworkCapabilities#getSSID to SystemApi" 2020-01-22 15:23:07 +00:00
Remi NGUYEN VAN
aa4c511696 Add NetworkCapabilities#getSSID to SystemApi
setSSID was added to the API, so it makes sense to have getSSID be part
of the API as well.

Test: m
Bug: 139268426
Change-Id: I6fa9c513ce4fb8ce1e3530776ce8fd5b2e77055e
2020-01-22 22:52:53 +09:00
Remi NGUYEN VAN
ead1ef41ee Add API for CaptivePortalData
CaptivePortalData will be used to hold data advertised by the network
following RFC7710bis.

To fetch the CaptivePortalData, the API URL is added to LinkProperties,
to be provided by the NetworkAgent.

Because CaptivePortalData can be used to guess user location (especially
from the URLs provided by the portal), it is only exposed to
applications that have privileged permissions.

Test: atest FrameworksNetTests
Bug: 139269711
Change-Id: I341175b5fece8ee00e19898af5e8eabe66cefbf3
2020-01-22 22:27:44 +09:00
Nathan Harold
d38b96e9b3 Remove StringNetworkSpecifier
Due to issues with @Deprecated @removed, manually remove
StringNetworkSpecifier. This API was never in any released
API surface; it was planned to be added in R; however, the
need was superseded by TelephonyNetworkSpecifier.

"Aaaaand it's gone!"

Bug: 147441267
Test: make aosp_bramble-userdebug
Change-Id: I9bae68a60f3cdb77203ba61ea8a08f64e597cf08
2020-01-22 05:39:30 +00:00
Chiachang Wang
23d5f84adc Merge changes from topic "networkagent"
am: 0ed49867e2

Change-Id: Iaebb3aaced18257f4beffacc13a0d87efa1a7ec7
2020-01-21 21:32:52 -08:00
Lorenzo Colitti
9e44006fb8 Rename NetworkMisc to NetworkAgentConfig.
am: 2dda9e0627

Change-Id: I1dae34487a5ea484c17895a2d7ae694e8ae1973a
2020-01-21 21:32:30 -08:00
Chiachang Wang
0ed49867e2 Merge changes from topic "networkagent"
* changes:
  Add a Builder to NetworkAgentConfig, and make it SystemApi.
  Rename NetworkMisc to NetworkAgentConfig.
2020-01-22 05:27:51 +00:00
Chiachang Wang
4fae98e083 Merge "Make NetworkAgent stop subclassing Handler."
am: a11ae54bee

Change-Id: Ie308e86e1b1173b0ec7fb7ac4a4f0b6c2bcfafa6
2020-01-21 20:42:19 -08:00
Chiachang Wang
a11ae54bee Merge "Make NetworkAgent stop subclassing Handler." 2020-01-22 04:33:31 +00:00
Cody Kesting
b125776009 Add ConnectivityDiagnosticsManager to System Server.
ConnectivityDiagnosticsManager should be accessed through
Context#getService. In order for this to be possible, it needs to be
defined as a service inside SystemServiceRegistry.

Bug: 146444622
Test: compiles.
Test: CTS testing in aosp/1211164
Change-Id: I6fe29441ecc9967a04ceb394b3bbe54830bef079
2020-01-21 08:31:56 -08:00
Remi NGUYEN VAN
938f330d63 Merge "Add NetworkRequest#satisfiedBy to SystemApi"
am: b8f9c4f5b2

Change-Id: I817020ac31dec9e10ea27fa38f07250f5c447de1
2020-01-21 06:21:11 -08:00