Commit Graph

560827 Commits

Author SHA1 Message Date
Cody Kesting
fb657c523b Define VcnStatusCallback#onVcnStatusChanged.
This CL defines VcnStatusCallback#onVcnStatusChanged for notifying
VcnStatusCallbacks when the status of their specified subscription group
changes. Specifically, status codes will be provided to notify callbacks
when a VCN is started, stopped, enters Safe Mode, and when there are no
matching VCNs.

Bug: 180659281
Test: atest FrameworksVcnTests
Change-Id: Icf686c3da6c5bdeeab88f60495d2ad438fa15692
2021-02-22 17:28:48 -08:00
Cody Kesting
32a2e39563 Merge "Expose VCN Network policy APIs." 2021-02-22 17:24:02 +00:00
Cody Kesting
f74c6031f1 Expose VCN Network policy APIs.
This CL exposes APIs used for a) receiving VCN Network policy updates
and b) applying VCN Network policies to a given Network. Specifically,
these APIs should be used to receive notifications from VcnManager
whenever a VCN Network policy may have changed - generally, following a
VCN starting up, tearing down, or entering Safe Mode.

When a VcnNetworkPolicyListener is notified of a policy change, the
listener should query VcnManager#applyVcnNetworkPolicy to receive the
updated VcnNetworkPolicyResult. This policy result informs the listener
of their resulting NetworkCapabilities and also whether a Network
teardown is required as a consequence of the policy change.

Bug: 177020190
Test: atest FrameworksVcnTests
Change-Id: Ied78a57973a4ceaa7ef4cd9feee64478137497b8
2021-02-22 17:23:40 +00:00
Cody Kesting
c70a7d6258 Merge changes I1ceccedd,Ide2c7302
* changes:
  Change Exception class references to use Class.getName().
  Define VcnNetworkPolicyListener for VCN transports.
2021-02-22 17:23:14 +00:00
Mathew Inwood
a3ab19e8f3 Merge "Set updateable:false explicitly in apex rules." 2021-02-22 16:56:13 +00:00
Eric Laurent
6c0a02ad30 Merge "[Bugfix]audio:force show safe volume warning dialog" 2021-02-22 13:47:10 +00:00
Joseph Pirozzo
9cabf5a07b Merge "Add BluetoothMapClient to system API" 2021-02-22 13:10:08 +00:00
Lucas Lin
654b0fff63 Merge changes I852e3a53,I86755647,I0ed8b0c6
* changes:
  Remove unused INetworkManagementService from IpSecService
  Use NetdUtils instead of NetworkManagementService in Vpn
  Use NetdUtils instead of NetworkManagementService in IpSecService
2021-02-22 06:49:39 +00:00
Treehugger Robot
9203e5b94a Merge "Revert "Revert "Delete VPN methods in ConnectivityManager.""" 2021-02-22 06:12:48 +00:00
Paul Hu
7d72edb937 Merge "Expose NetworkWatchlistManager#getWatchlistConfigHash" 2021-02-22 05:23:04 +00:00
Paul Hu
19af44e2ce Merge "Stop using SysetmConfig#getSystemPermissions on PermissionMonitor" 2021-02-22 05:22:37 +00:00
Paul Hu
fb70ef5a24 Merge "Remove ArrayUtils usage in connectivity classes" 2021-02-22 05:22:01 +00:00
Lorenzo Colitti
fd6a27bf49 Revert "Revert "Delete VPN methods in ConnectivityManager.""
1. Stop using ConnectivityManager for VPNs in VpnDialogs.
2. Delete updateLockdownVpn, since all callers have been migrated
   to calling VpnManager directly.
3. Delete the call to VpnManager in factoryReset, since the only
   caller (ResetNetworkConfirm) has been updated to call into
   VpnManager directly.
4. Delete getVpnManager, since it is now unused.

This reverts commit 51bf8e979e.

Reason for revert: should be safe to submit now that aosp/1596096 is merged

Bug: 173331190
Test: treehugger
Change-Id: Ife3607c024006ce4fe46c981e9742170becb6331
2021-02-22 05:07:22 +00:00
Treehugger Robot
6b501d8acf Merge "Use RouteInfo API constructor in VpnService" 2021-02-22 04:05:51 +00:00
Jack Yu
8359ebecc3 Merge "Simplified the initial attach APN logic" 2021-02-21 18:14:03 +00:00
Orion Hodson
0248d32dc3 Merge "libandroid_runtime,libhwui: use libnativehelper_lazy" 2021-02-21 10:03:21 +00:00
Jack Yu
d5f25c2262 Simplified the initial attach APN logic
1. Instead of using the hardcoded order, read the order
   from configuration. This also allows carriers to specify
   the allowed types of APN can be used for initial attach.
2. Removed the preferred APN logic. The preferred APN is
   specifically for the default APN after a successful data
   setup. It's not related to initial attach.

Fix: 169657628
Test: Manual
Merged-In: I9fbf4f270726cba1281770db88fec7c1bb62e6db
Change-Id: I9fbf4f270726cba1281770db88fec7c1bb62e6db
(cherry picked from commit 0bebba7378)
2021-02-21 01:23:25 -08:00
James Mattis
1444e3eea1 Merge "Using defensive copy for default request remove" 2021-02-21 04:28:13 +00:00
James Mattis
ff5fb79411 Using defensive copy for default request remove
Passing in a defensive copy for the default requests in
ConnectivityService prior to updating that collection so as to not have
issues when removing elements as part of the per-app preference update
flow.

Bug: 176494815
Bug: 178632672
Test: atest FrameworksNetTests
atest FrameworksNetTests:com.android.server
.ConnectivityServiceTest#testSetOemNetworkPreference
ClearPreviousOemValues --iterations

Change-Id: Ia683d5035dda2be35fd2f2b7ee038e806caab6f9
2021-02-20 15:51:24 -08:00
James Mattis
c1115803bc Merge "Unit test automation for Multilayer Evaluation" 2021-02-20 21:23:45 +00:00
Treehugger Robot
08bf2e8f49 Merge "Keystore 2.0: Revisite Authorization.java" 2021-02-20 19:26:58 +00:00
Junyu Lai
3237216211 Merge "[FUI15] Remove networkId in NetworkState" 2021-02-20 14:00:19 +00:00
paulhu
0ab41fc1f3 Stop using SysetmConfig#getSystemPermissions on PermissionMonitor
Repalace the API with SysetmConfigManager#getSystemPermissionUids
and update the design/test accordingly.

Bug: 177188455
Test: atest FrameworksNetTests
Test: atest FrameworksNetIntegrationTests
Test: atest CtsNetTestCases
Change-Id: I8b553b934252b93c60b815715680427a41620054
2021-02-20 16:20:19 +08:00
Treehugger Robot
bfc1f6b382 Merge "Integrate IKeystoreUserManager aidl with LockSettingsService." 2021-02-20 06:57:04 +00:00
Chiachang Wang
63bc7bd3c2 Merge changes I0a75c440,Ief9e8925,Ie03e8276,If0ac9a64,I716bd771
* changes:
  [IT06]Move INetworkActivityListener into connectivity module
  [IT05] Remove the unused network activity logic out from NMS
  [IT4.7] Add network activity info into dumpsys for debugging
  [IT4.6] Unbundle NMS out from ConnectivityManager
  [IT4.5] Update radio power from CS directly
2021-02-20 02:02:46 +00:00
James Mattis
a917e5a283 Unit test automation for Multilayer Evaluation
Unit test automation for multilayer network hierarchy evaluation
when using the setOemNetworkPreference() API ConnectivityService.

Bug: 178632672
Bug: 176494815
Bug: 170068946
Test: atest FrameworksNetTests
Change-Id: Ia9b76f49a07eff6a3977faaa41fc67a10f307841
2021-02-19 17:41:01 -08:00
James Mattis
ed4288b164 Merge "Unit tests for Multi-Default with Existing APIs" 2021-02-20 01:38:52 +00:00
Hasini Gunasinghe
13dd61336f Integrate IKeystoreUserManager aidl with LockSettingsService.
This CL introduces the client side for IKeystoreUserManager aidl and
integrates it with the LockSettingsService.

Bug: 171305115
Test: TBD
Change-Id: I7560e98f95aaec6b85cdcfc01ba83aea0ccc52ae
2021-02-19 15:34:10 -08:00
Janis Danisevskis
377370cce8 Keystore 2.0: Revisite Authorization.java
Test: N/A
Change-Id: I4da26175741c5313aec17d30a3e534a2172d87b4
2021-02-19 15:31:15 -08:00
Makoto Onuki
5fea1d9a01 Merge "Add a missing NULL check for postActivityStartTokenRemoval()" 2021-02-19 21:08:30 +00:00
Jeff Sharkey
2a1600625c Merge "Add OWNERS for palette library" 2021-02-19 18:07:34 +00:00
James O'Leary
2964b50d79 Add OWNERS for palette library
- dupin@ landed the folder & code in it originally
- good idea to move review off the plates of generic frameworks/base
OWNERS

Change-Id: I03a1e8ec00d5b658ee026a44038703e5b31ca52e
2021-02-19 18:04:06 +00:00
Anthony Stange
5927064796 Merge "Add owners for files related to the sensors framework" 2021-02-19 17:23:45 +00:00
Joseph Pirozzo
f3bf66ac7a Add BluetoothMapClient to system API
Add BluetoothMapClient.sendMessage to system API for use by mainline
modules.

Bug: 157948464
Test: atest BluetoothInstrumentationTests
Tag: #feature
Change-Id: Idee4cb2cefeaf03f0351ea576f919a294219d391
2021-02-19 07:39:07 -08:00
Nataniel Borges
7096deadf4 Merge "Revert "Delete VPN methods in ConnectivityManager."" 2021-02-19 15:32:46 +00:00
Nataniel Borges
51bf8e979e Revert "Delete VPN methods in ConnectivityManager."
This reverts commit 279b79f062.

Bug: 180710918
Reason for revert: Broken build 

Change-Id: I6e6318b4c01ccab27ca3e9f16bb2194aa1d9ffd2
2021-02-19 15:25:33 +00:00
Lorenzo Colitti
e8817c1796 Merge "Delete VPN methods in ConnectivityManager." 2021-02-19 14:56:04 +00:00
Lorenzo Colitti
279b79f062 Delete VPN methods in ConnectivityManager.
1. Stop using ConnectivityManager for VPNs in VpnDialogs.
2. Delete updateLockdownVpn, since all callers have been migrated
   to calling VpnManager directly.
3. Delete the call to VpnManager in factoryReset, since the only
   caller (ResetNetworkConfirm) has been updated to call into
   VpnManager directly.
4. Delete getVpnManager, since it is now unused.

Test: m
Bug: 173331190
Change-Id: I5d071281c0e36f6523fea10671a9abf994c66d66
2021-02-19 17:34:30 +09:00
Lorenzo Colitti
b9c396b87a Merge changes I0e6df469,I3d46d5f7
* changes:
  Fix testMobileDataAlwaysOn flakiness
  Speed up NetworkFactory tests.
2021-02-19 08:13:38 +00:00
Treehugger Robot
6ec31401b4 Merge "Stop using ConnectivityManager for VPNs in DPMS." 2021-02-19 08:09:56 +00:00
Lorenzo Colitti
6c77e14663 Merge "Fix all Log.wtfs in FrameworksNetTests." 2021-02-19 07:49:27 +00:00
paulhu
5119787a27 Expose NetworkWatchlistManager#getWatchlistConfigHash
Connectivity is becoming a mainline module in S and
ConnectivityService is used this API for getting watch list
configurations. However, Mainline modules are not allowed to use
non-formal APIs. Thus, make this API as module-lib api to support
the usage.

Bug: 172183305
Test: make update-api
Change-Id: I21ce5f158850892926b92cf6347c61a57ac95b72
2021-02-19 15:30:02 +08:00
Treehugger Robot
394170f9cc Merge "Use formal API for ActivityThread to set proxy" 2021-02-19 05:42:06 +00:00
Josh Gao
ecc474af3b Merge "NativeTombstoneManager: catch ProtoParseException." 2021-02-19 05:02:16 +00:00
Remi NGUYEN VAN
72887073f2 Use formal API for ActivityThread to set proxy
Add setHttpProxyConfiguration to the public API, and use
ConnectivityManager APIs from ActivityThread (instead of hidden APIs) to
get/set the proxy for an app process.

The default proxy is now initialized with getDefaultProxy instead of
getProxyForNetwork(null); this should not make a difference, as nothing
should have called bindProcessToNetwork at that point yet.

Bug: 174436414
Test: m; device boots
Merged-In: Ifb516194ecde1567cea4b6806946091cdcf2f015

Change-Id: I06b797eeae54609aecdc0afe1df4e6c602a17a69
2021-02-19 13:53:56 +09:00
Remi NGUYEN VAN
09bbad130d Merge "Split parcelable .aidl files to aidl-export" 2021-02-19 02:21:25 +00:00
Treehugger Robot
41663a0eb6 Merge "Fix OverlayDeviceTests for un-rooted devices" 2021-02-19 01:12:21 +00:00
Cody Kesting
a4c27eea1a Change Exception class references to use Class.getName().
This CL updates references to fully qualified Exception names (such as
"java.lang.RuntimeException") to get the Exception name through the
Exception's Class Object (e.g. RuntimeException.class.getName()).

Bug: 163433613
Test: atest FrameworksVcntests
Change-Id: I1ceccedda0a513a8c41caaef752d9f0005eceac0
2021-02-18 16:40:54 -08:00
Cody Kesting
901dc86e4b Define VcnNetworkPolicyListener for VCN transports.
This CL defines VcnNetworkPolicyListener and VCN Network policy
functions for VcnManager. Specifically, VcnNetworkPolicyListeners should
be added and removed by Network factories as they bring up and teardown
data Networks.

VcnNetworkPolicyListeners are used by VcnManagementService to notify
transports when they should re-query for their updated
VcnNetworkPolicyResults - done via VcnManager#applyVcnNetworkPolicy.
Policy results inform transports what the current NetworkCapabilities
are based on their VCN policy, and also whether the transport should
teardown and restart.

Bug: 177020190
Test: atest FrameworksVcnTests
Change-Id: Ide2c73025f4ffceabf7955f219a79be5a9bdc0d9
2021-02-18 16:31:08 -08:00
Ryan Mitchell
de8d74fb77 Fix OverlayDeviceTests for un-rooted devices
The AndroidText.xml needs the root preparer to run on non-rooted
devices.

Bug: 177115481
Bug: 180623619
Test: adb unroot && atest OverlayDeviceTests
Change-Id: I4377207428182fbb76c09abef248b69eeae6acf5
Merged-In: I4377207428182fbb76c09abef248b69eeae6acf5
2021-02-18 23:56:24 +00:00