Commit Graph

560494 Commits

Author SHA1 Message Date
Treehugger Robot
39d22680c9 Merge "Do not propogate test api access flags to Zygote." 2021-02-08 15:27:19 +00:00
Treehugger Robot
4d20423db6 Merge "preloaded-classes-denylist: remove retired class" 2021-02-08 15:10:57 +00:00
Lorenzo Colitti
dbe68e90d7 Merge "Switch VpnDialogs from IConnectivityManager to IVpnManager." 2021-02-08 14:09:09 +00:00
Orion Hodson
cd272e3402 preloaded-classes-denylist: remove retired class
Remove com.android.server.BootReceiver$2 from the denylist as this
anonymous class was retired in change https://r.android.com/1565971.

(cherry picked from commit 1653aba6bf)

Bug: 159164105
Bug: 179645293
Test: atest PreloadCheck
Change-Id: I94122241dc4cef84524ca83513a68d1fa8ffbe65
Merged-In: I94122241dc4cef84524ca83513a68d1fa8ffbe65
2021-02-08 13:24:41 +00:00
Lorenzo Colitti
be331ab3a7 Merge changes I4256ca5f,I91528e1a,I48bd594c
* changes:
  Change ConnectivityServiceTest to prepare for VPN code move.
  Add to VpnManager the VPN APIs used by Settings and SystemUI.
  Remove temporary hack in VpnTest.
2021-02-08 10:41:32 +00:00
Chiachang Wang
385f58bf71 Merge "Move shared Proxy method and constants to shared lib" 2021-02-08 10:27:05 +00:00
Lorenzo Colitti
a5e942370f Switch VpnDialogs from IConnectivityManager to IVpnManager.
The VPN code is moving out of ConnectivityService to a new
VpnManagerService. Update VpnDialogs to call into the new
service.

Bug: 173331190
Test: builds, boots
Test: atest HostsideVpnTests
Change-Id: I173ed0c3e39afb91c0dde1426dc492e9225afb00
2021-02-08 19:25:40 +09:00
Chiachang Wang
698749b053 Move shared Proxy method and constants to shared lib
The static validate() method an PROXY_* constants in Proxy are
used by both module and Settings. After Proxy is moving into
connectivity module, Setting will not able to access them.
Thus, move them to ProxyUtils in net shared lib.

Bug: 172183305
Test: atest FrameworksNetTests
Test: atest CtsNetTestCases:ProxyInfoTest
Change-Id: I02c88aeaeb53d62b87a42a2d8ead9b140b054650
2021-02-08 10:25:07 +00:00
Treehugger Robot
648c2e4c98 Merge "[VCN03] Linger the newly connected network for a short time" 2021-02-08 04:57:35 +00:00
Chiachang Wang
af6494310d Merge "Create new system API in UserHandle to get uid" 2021-02-08 03:56:39 +00:00
Xiao Ma
988d3f818b Merge "Allow connectivity namespace to enable native level access flags." 2021-02-08 01:40:51 +00:00
Treehugger Robot
905c2570cd Merge "Fix a bug in the USAP Pool refill logic." 2021-02-07 19:52:20 +00:00
Lorenzo Colitti
7a4c248582 Merge "More cleanly separate requests and listens." 2021-02-07 18:04:50 +00:00
Lorenzo Colitti
9ce4107f11 Change ConnectivityServiceTest to prepare for VPN code move.
No-op changes to make it easier to review the VPN code move.
1. Set underlying networks via MockVpn, not ConnectivityService.
2. Add a processBroadcastForVpn utility method that we can modify
   without too much churn when the code is moved.

Bug: 173331190
Test: test-only change
Change-Id: I4256ca5f33034ef9d1de79857795a6ed1d644e61
2021-02-07 20:40:52 +09:00
Lorenzo Colitti
a835b390cd Add to VpnManager the VPN APIs used by Settings and SystemUI.
Settings and SystemUI use these through raw AIDL calls.
Make them proper manager calls so we can move the implementation
without touching the callers again.

For now these still call into ConnectivityService via
IConnectivityManager. In an upcoming CL the implementation will
move to VpnManagerService.

Test: m
Bug: 173331190
Change-Id: I91528e1ad9948fbaa1fc5e37c61c5eb95f54964e
2021-02-07 20:40:51 +09:00
Lorenzo Colitti
001e831df7 Remove temporary hack in VpnTest.
This temporary hack was necessary due to b/175883995. Now that
that bug is fixed, remove the hack.

Bug: 171529940
Test: test-only change
Change-Id: I48bd594cf3a37575f4888c1be9a1cf535de2e4d2
2021-02-07 20:40:46 +09:00
Lorenzo Colitti
97d09a263f More cleanly separate requests and listens.
Currently, NetworkRequest has several types of requests (LISTEN,
TRACK_DEFAULT, REQUEST, BACKGROUND_REQUEST), and we expect more
to be added.

There are really three categories of request:
1. Requests satisfied by only one network and will keep that
   network up, and thus need to be sent to NetworkProviders:
   REQUEST, BACKGROUND_REQUEST.
2. Requests satisfied by only one network but will not keep that
   network up: TRACK_DEFAULT
3. Requests satisfied by multiple networks and will not keep any
   networks up: LISTEN.

Unfortunately the separation is not very clear. Currently, for
any valid request, either isListen() will return true or
isRequest() will return true. This makes it impossible to tell
whether a particular request should be sent to NetworkProviders,
so the current code sends TRACK_DEFAULT requests to
NetworkProviders as well. This is incorrect - a TRACK_DEFAULT
should never keep a network up, for example.

This CL attempts to clarify things by making isRequest() return
false for TRACK_DEFAULT requests and thus never sending them to
NetworkProviders. After this CL:

- isRequest will return true only for requests that attempt to
  bring up or keep up a network.
- isListen will return true only for requests that match multiple
  networks but do not keep any of them up.
- Neither will return true for TRACK_DEFAULT.

Test: atest ConnectivityServiceTest
Change-Id: I7aad30ade8f7ab2a179e53483d9afd8675f64a12
2021-02-07 18:20:59 +09:00
Serik Beketayev
57a531fdd6 Merge "Revert "[Mainline] Migrate android.utils package items"" 2021-02-07 03:11:47 +00:00
Serik Beketayev
28c40e2d49 Revert "[Mainline] Migrate android.utils package items"
Revert submission 1553146-android_util

Reason for revert: Build Breakage aosp-master/db845c-userdebug @ 7128996
Reverted Changes:
Ia39f6e03f:[Mainline] Migrate android.utils package items
Iaf99140d6:[Mainline] Migrate android.utils package items

Change-Id: I5bdaec5d1a87436510c3e05fadaf0124d86b1bdf
2021-02-06 09:19:47 +00:00
Serik Beketayev
85e724153e Merge "[Mainline] Migrate android.utils package items" 2021-02-06 07:00:12 +00:00
Treehugger Robot
2ced350043 Merge "Keystore 2.0: Fix getKey returns null on key not found." 2021-02-06 04:43:49 +00:00
James Mattis
f76916a1c9 Merge changes Iabad7300,I85363e28
* changes:
  Stubbed setOemNetworkPreference in Connectivity
  Update OemNetworkPreferences to use 1:1 Map
2021-02-06 04:33:51 +00:00
Treehugger Robot
39338deffe Merge "[Mainline] Core Platform APIs migration" 2021-02-06 04:11:00 +00:00
Treehugger Robot
07f94fbb01 Merge "Keystore 2.0 SPI: Add NAMESPACE_WIFI." 2021-02-06 04:08:13 +00:00
junyulai
6a9c1e04cf [VCN03] Linger the newly connected network for a short time
This is mainly used by VCN, where VCN-eligible networks might
be registered before VCN management service can fire request
to prevent the newly created network from being torndown
immediately by ConnectivityService.

Test: atest ConnectivityServiceTest#testNewNetworkLingering
      atest ConnectivityServiceTest#testNewNetworkLingering_bgNetwork
      atest FrameworksNetTests --rerun-until-failure 20
Bug: 175180558
Change-Id: I7768daf4cf2d8f6d8057b5107412e06104ba82e0
2021-02-06 11:22:31 +08:00
Jeff Sharkey
072c9b4cc4 Merge "Add OWNERS" 2021-02-05 21:48:07 +00:00
Dmitri Plotnikov
34f667b5c7 Add OWNERS
Change-Id: Ia81dd386551db0a3c8bc73c03a6991b3c7c05770
2021-02-05 21:41:15 +00:00
Josh Gao
ddaf564365 Merge changes I8b85d8ee,I789f41f1
* changes:
  Parse proto tombstones.
  Extract tombstone tracking to a separate service.
2021-02-05 20:11:10 +00:00
Tianjie Xu
90772648cd Merge "Update Java doc for ResumeOnReboot" 2021-02-05 18:36:48 +00:00
Kholoud Mohamed
de2340c0e9 Merge "Grant shell QUERY_USERS and MODIFY_QUIET_MODE" 2021-02-05 18:12:57 +00:00
Jeff Sharkey
460b1255a9 Merge "Add People widgets to those owned by System UI Notifications team" 2021-02-05 18:12:05 +00:00
Jeff Sharkey
29ff8b410a Merge "add owners" 2021-02-05 18:09:06 +00:00
Janis Danisevskis
b6a9ed2f65 Keystore 2.0: Fix getKey returns null on key not found.
Test: CTS test.
Change-Id: I2a1edcf275da02cf005b6600450d152530eceaa9
2021-02-05 09:50:34 -08:00
Anton Hansson
6869137dfa Merge "Temporarily add IKE to non-updatable stubs build" 2021-02-05 17:29:05 +00:00
Cody Kesting
9a5b717514 Merge changes I128a894c,I3336c150
* changes:
  Remove use of locks in VcnGatewayConnection.
  Support Safemode for VCNs.
2021-02-05 17:03:15 +00:00
Anton Hansson
e4d468f16d Merge "Update references to prebuilt sdks to use "current"" 2021-02-05 16:54:19 +00:00
Jeff DeCew
d5e38f04bb Add People widgets to those owned by System UI Notifications team
Change-Id: I15afb8f80a3d067af522707748a5b07c015af138
2021-02-05 14:09:02 +00:00
Anton Hansson
bad51dd74b Merge "Move shared module build rules to common repo" 2021-02-05 12:42:58 +00:00
Anton Hansson
b7d532e4c8 Temporarily add IKE to non-updatable stubs build
...in order to be able to resolve IKE classes. Note that this can be
removed once the prebuilt stub in prebuilts/sdk contains IKE, which
can be achieved with a new import after this CL is submitted:
I10759d22eaba4861b7d7f283b551156f09f54675

Bug: 177266501
Test: m
Change-Id: I7229b1486e7170acca5da8f1b7874e5eaaecb1db
2021-02-05 11:40:25 +00:00
Anton Hansson
ce21e28bfc Update references to prebuilt sdks to use "current"
This facilities easier updating when new classes get added.

Bug: 177266501
Test: m
Change-Id: I85b3832681f0455093d2a33ace7dbc1028a1a5ff
2021-02-05 11:38:30 +00:00
Aaron Huang
2954e8af0f Merge "Update VpnTest for new restricted API" 2021-02-05 10:52:54 +00:00
Treehugger Robot
577fd4a912 Merge "Add @Nullable to Object#equals()" 2021-02-05 09:36:41 +00:00
Junyu Lai
fb2c686fb1 Merge "[VCN09] Rename linger timer" 2021-02-05 09:29:12 +00:00
Frank Li
ec30b1105c Merge "[CS04]Remove hidden API usage of NetworkCapabilities" 2021-02-05 08:29:42 +00:00
Remi NGUYEN VAN
2e2dda5a9f Merge "Remove legacy network factories" 2021-02-05 08:23:19 +00:00
junyulai
0452d4a2aa [VCN09] Rename linger timer
Linger timer mechanism will be used for both "linger" and
"nascent" states. To prevent confusion, rename the linger
timer and related functions to more generic name.

Test: TH
Bug: 175180558
Change-Id: I652f7c65c2f8bc58fb9d3316480f23a9709eccce
2021-02-05 15:57:07 +08:00
Lorenzo Colitti
ace52c4ff8 Merge changes Ieb7f33bc,I81b56862
* changes:
  Fix the legacy VPN tests that start racoon.
  Make testLegacyLockdownVpn more realistic.
2021-02-05 07:34:43 +00:00
Roman Kalukiewicz
9b9af7777d Add @Nullable to Object#equals()
This is a partial cherry-pick of change:
I5eedb571c9d78862115dfdc5dae1cf2a35343580

for connectivity classes.

Bug: 170883422
Test: m
Merged-In: I5eedb571c9d78862115dfdc5dae1cf2a35343580
Change-Id: I7dc661863b73f4198ddb4f3a1566583d0f07db3c
2021-02-05 07:28:44 +00:00
Jiachen Zhao
d5567fea8e Update Java doc for ResumeOnReboot
Update doc for onWrap/onUnwrap functions to further clarify how
exceptions should be thrown.

Bug: 172780686
Test: TH
Change-Id: I2bd8b80648074d0b6026487cb0b5791dca6cdc18
2021-02-05 07:18:32 +00:00
Paul Hu
830e1e9576 Merge "Replace NPMI#isUidNetworkingBlocked()" 2021-02-05 06:38:02 +00:00