Commit Graph

13132 Commits

Author SHA1 Message Date
Treehugger Robot
ec9bb8cd13 Merge "Update frameworks to use unbundled version of BouncyCastle." am: 9671b7eca8 am: f477bba3c4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1559779

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I573badb280d7e351dad049c94566a68f9498f730
2021-02-02 15:34:40 +00:00
Junyu Lai
ca31512d50 Merge "[VCN08] Expose NOT_VCN_MANAGED capability as system API" am: 2c5d744e80 am: 6c21a4dfde
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1563497

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ib2b868b8e3be84e3e16fdf9a5c216b270e76e32e
2021-02-02 15:34:23 +00:00
Treehugger Robot
f477bba3c4 Merge "Update frameworks to use unbundled version of BouncyCastle." am: 9671b7eca8
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1559779

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I691da785142fee5967674ac2cf1261e71c1f16e3
2021-02-02 14:41:24 +00:00
Junyu Lai
6c21a4dfde Merge "[VCN08] Expose NOT_VCN_MANAGED capability as system API" am: 2c5d744e80
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1563497

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I48f029e663fe397ce0f88d2de7a758530c093012
2021-02-02 14:37:47 +00:00
Treehugger Robot
9671b7eca8 Merge "Update frameworks to use unbundled version of BouncyCastle." 2021-02-02 14:37:05 +00:00
Junyu Lai
2c5d744e80 Merge "[VCN08] Expose NOT_VCN_MANAGED capability as system API" 2021-02-02 13:57:57 +00:00
Lorenzo Colitti
89ef449561 Merge changes I4f38a539,Id4f6c7f4 am: 7b49264237 am: 6964d11672 am: 79f031dadc
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1565198

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I49cd86725c481827b4278e05afd4847c3a06e8d7
2021-02-02 11:49:08 +00:00
Lorenzo Colitti
79f031dadc Merge changes I4f38a539,Id4f6c7f4 am: 7b49264237 am: 6964d11672
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1565198

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I01f1b30d188e4cedcdb34bcd8f7f25ac1a5c64b4
2021-02-02 11:30:18 +00:00
Lorenzo Colitti
6964d11672 Merge changes I4f38a539,Id4f6c7f4 am: 7b49264237
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1565198

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Id68e4e0ff5995bbf04859834fb2aa0936ef651bc
2021-02-02 10:46:37 +00:00
Paul Hu
2dc9b85d6a Merge "Remove ArrayUtils usage in connectivity frameworks classes" am: e59f31b85a am: 03b2f0dfda am: 63fd256cfb
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1564776

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia926472336a8abfa6583f29f452838056db932a8
2021-02-02 10:09:24 +00:00
Lorenzo Colitti
7b49264237 Merge changes I4f38a539,Id4f6c7f4
* changes:
  Add the underlying networks to NetworkAgentInfo#toString.
  Improve testing for network blocking.
2021-02-02 10:06:03 +00:00
Paul Hu
63fd256cfb Merge "Remove ArrayUtils usage in connectivity frameworks classes" am: e59f31b85a am: 03b2f0dfda
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1564776

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1915652c73514ea7800911222b68253e07e719a9
2021-02-02 09:32:27 +00:00
Paul Hu
03b2f0dfda Merge "Remove ArrayUtils usage in connectivity frameworks classes" am: e59f31b85a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1564776

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia8063e83503dce99985e999235ab7eb75f7cd747
2021-02-02 09:07:11 +00:00
Paul Hu
e59f31b85a Merge "Remove ArrayUtils usage in connectivity frameworks classes" 2021-02-02 08:47:04 +00:00
Lorenzo Colitti
b852199e0a Add the underlying networks to NetworkAgentInfo#toString.
This is useful in debugging VPN networks.

Bug: 173331190
Test: manual
Change-Id: I4f38a53980191a1813c2ef313fedc51af98f18f6
2021-02-02 16:17:22 +09:00
Lorenzo Colitti
786947b4ac Improve testing for network blocking.
This simplifies the uidNetworkingBlocked method and makes it more
realistic by supporting more combinations of rules than just the
four used by this test.

Also support RULE_ALLOW_METERED, and add test coverage for it.

Test: test-only change
Change-Id: Id4f6c7f41429f3ae7841d3214b3e5e95ec591f85
2021-02-02 16:17:22 +09:00
Treehugger Robot
8a02f29993 Merge "Have connectivity self-register manager classes" am: 5dea66088e am: b16235f683 am: a4adae9feb
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552657

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7a664bb9e9f2f835f148d0102f8b53c010bb7791
2021-02-02 06:40:07 +00:00
Treehugger Robot
a4adae9feb Merge "Have connectivity self-register manager classes" am: 5dea66088e am: b16235f683
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552657

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I512f95a45ab23d4b7e03c196850d0dab75223620
2021-02-02 06:07:13 +00:00
Treehugger Robot
b16235f683 Merge "Have connectivity self-register manager classes" am: 5dea66088e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552657

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I73f3c0c312ae9e1786204776e98240c259416a8b
2021-02-02 05:43:12 +00:00
Lucas Lin
608940fe23 Merge "Use function inside NetdUtils instead of NetworkManagementService" am: 8ecb705379 am: 89dfaaee8d am: fd33d7f4fe
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1534904

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3e3394be59677823631e551f83484f1a2514b274
2021-02-02 05:09:17 +00:00
Treehugger Robot
5dea66088e Merge "Have connectivity self-register manager classes" 2021-02-02 05:01:04 +00:00
lucaslin
009c9e6773 Reimplement [read|write]ArraySet of Parcel inside NetworkCapabilities
Both of readArraySet and writeArraySet are hidden APIs inside
Parcel, so reimplement those two methods inside NetworkCapabilities
to prevent calling hidden APIs.

Bug: 170598012
Test: atest FrameworksNetTests
Change-Id: I70f75c1a0db92c6a5575c6a9917843d783dfaeea
2021-02-02 12:57:26 +08:00
Lucas Lin
fd33d7f4fe Merge "Use function inside NetdUtils instead of NetworkManagementService" am: 8ecb705379 am: 89dfaaee8d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1534904

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2ac6a7d01878a646c4f19f6e0d54f948c7ec79eb
2021-02-02 04:41:36 +00:00
Lucas Lin
89dfaaee8d Merge "Use function inside NetdUtils instead of NetworkManagementService" am: 8ecb705379
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1534904

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ibc30a45e691ec76703452595b62b588b78cd8048
2021-02-02 04:18:56 +00:00
Lucas Lin
8ecb705379 Merge "Use function inside NetdUtils instead of NetworkManagementService" 2021-02-02 03:38:38 +00:00
junyulai
ad1760bd6d [VCN08] Expose NOT_VCN_MANAGED capability as system API
Test: m -j doc-comment-check-docs
Fix: 177299683
Bug: 175662146
Change-Id: Iaa53d21774ea48af5fe339b57bf1235c77f295a0
2021-02-02 11:34:09 +08:00
Serik Beketayev
2c294e786d Merge "[Mainline] Migrate com.google.android.collect pkg" am: 9b3338820a am: cd3b07080b am: 223c551196
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552881

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7aa42de207124ca9e8646324cd4b57834c341ad6
2021-02-02 01:27:24 +00:00
Jeongik Cha
cdd223033d Specify version for aidl_interface explicitly
Bug: 150578172
Test: m
Change-Id: I4c909903521cd8a766dca5312edd98d17b9e1308
2021-02-02 10:11:31 +09:00
Serik Beketayev
223c551196 Merge "[Mainline] Migrate com.google.android.collect pkg" am: 9b3338820a am: cd3b07080b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552881

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ica65ce3224b636cf71b69e37ff9f36315e9309f5
2021-02-02 00:31:05 +00:00
Serik Beketayev
cd3b07080b Merge "[Mainline] Migrate com.google.android.collect pkg" am: 9b3338820a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552881

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1648cf0bc1803d59787edb8715b0abc63728cc5d
2021-02-01 23:50:59 +00:00
Serik Beketayev
9b3338820a Merge "[Mainline] Migrate com.google.android.collect pkg" 2021-02-01 23:11:56 +00:00
Chalard Jean
efb8409f66 [NS] Tests : don't expect a score in NF#acceptRequest
The score argument is going away, so there no longer
is a need to test it. It's never been used by anybody
and is actually a problem going forward.

Since removing the argument requires a small re-arch
of the testing tool anyway, rebuild expecting requests
on top of TrackRecord. This simplifies the test a
great deal, as well as (as observed in running the
tests) makes the test faster.

Test: this
Change-Id: If03b9e64f14ac8ffa5398b964939a9a45a74b28d
2021-02-01 23:06:49 +09:00
Adrian Roos
14c08d26d5 API: Suppress existing NullableCollections lints
Bug: 152525509
Bug: 154763999
Test: make checkapi
Change-Id: Iecd0927e6be5496b2fbd1a49396db5439257ffe4
2021-02-01 15:04:10 +01:00
Lorenzo Colitti
ec960a86ce Merge changes Idcc9e32c,I58769bb7 am: e73a36ba21 am: 203c72f86c am: 910fb03907
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552503

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3d15c00910467d51531a25c025efb491b446b6a4
2021-02-01 12:41:24 +00:00
Lorenzo Colitti
910fb03907 Merge changes Idcc9e32c,I58769bb7 am: e73a36ba21 am: 203c72f86c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552503

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I309434985d7dc6c1cbcb411f6f08ebc4dc5d37d4
2021-02-01 12:20:27 +00:00
Lorenzo Colitti
203c72f86c Merge changes Idcc9e32c,I58769bb7 am: e73a36ba21
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552503

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If12227f11585de18d92995cf603765b18f91764f
2021-02-01 11:36:03 +00:00
Remi NGUYEN VAN
a8780c8ea1 resolve merge conflicts of bff19645ef to sc-dev
Bug: None, merge conflict
Change-Id: Id07440d6a55111a1a7ddbf3df306f4466073fd1d
2021-02-01 11:29:28 +00:00
Lorenzo Colitti
e73a36ba21 Merge changes Idcc9e32c,I58769bb7
* changes:
  Remove getFilteredNetworkState and add @NonNull in NetworkState.
  Add test coverage for get*NetworkInfo on metered networks.
2021-02-01 10:56:19 +00:00
Remi NGUYEN VAN
bff19645ef Merge "Move module sources to packages/Connectivity" am: 3d70ab73eb am: f172ba283d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552656

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8261b01b976b4d8009cd028fa113ef8bede74acb
2021-02-01 08:41:56 +00:00
paulhu
4797107480 Remove ArrayUtils usage in connectivity frameworks classes
Instead, use CollectionUtils from frameworks/libs/net.

Bug: 174541037
Test: atest FrameworksNetTests
Change-Id: I610e00302cf76510e9e34ac8a9a5f738e5ecd0c7
2021-02-01 16:30:08 +08:00
Remi NGUYEN VAN
fe97b48b6e Have connectivity self-register manager classes
As connectivity services are planned to move to a separate module, move
the manager classes registration from SystemServiceRegistry to
ConnectivityServicesRegistrar, using the registerContextAwareService
APIs.

This follows patterns and naming in WifiFrameworkInitializer.

Bug: 171540887
Test: device boots, connectivity working
Change-Id: I62ced1275750c73f209bac8ec3a3204b95695b83
2021-02-01 17:10:39 +09:00
Lorenzo Colitti
6f55e61287 Remove getFilteredNetworkState and add @NonNull in NetworkState.
getFilteredNetworkState is only used in two places, both of which
use only small parts of the NetworkState that is returned to
them. Remove the method and replace it with inline code in the
two callers. NetworkState is a fairly expensive object, and this
removes the need to perform lots of defensive copies of data that
the caller does not need.

Also remove the only call to the NetworkState constructor in
ConnectivityService. That leaves only one caller to the
NetworkState constructor, the one in NetworkAgentInfo. This
constructor is called with defensive copies of NetworkInfo,
LinkProperties, and NetworkCapabilities, so mark these three
parameters as @NonNull. It's also called with a non-null
Network, because NetworkAgentInfo is only constructed with
non-null Networks, so mark the network parameter @NonNull as
well.

In order to make the arguments in the NetworkState constructor
@NonNull, introduce a new constructor that sets everything to
null and make NetworkState.EMPTY call it.

Test: atest FrameworksNetTests
Change-Id: Idcc9e32c53533b0cf61494517e62d4c184fa7610
2021-02-01 16:12:04 +09:00
Lorenzo Colitti
0e920055dc Add test coverage for get*NetworkInfo on metered networks.
Test: test-only change
Change-Id: I58769bb768978d0acff1da6d32c2f6942c43508b
2021-02-01 15:58:12 +09:00
Remi NGUYEN VAN
f172ba283d Merge "Move module sources to packages/Connectivity" am: 3d70ab73eb
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1552656

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I42989abf6e81a4c0e7bed6b0890a1ee4f2c30191
2021-02-01 06:09:33 +00:00
Remi NGUYEN VAN
8f37b3f55b Move module sources to packages/Connectivity
Files that are planned to be part of the connectivity module are grouped
in packages/Connectivity, so they can be built separately and moved in
one operation with their history into packages/modules/Connectivity.

This places the files in the existing framework-connectivity-sources
filegroup instead of the current framework-core-sources filegroup. Both
are used the same way in framework-non-updatable-sources.

Bug: 171540887
Test: m
Change-Id: I62d9d91574ace6f5c4624035d190260c3126b91e
2021-02-01 11:52:14 +09:00
Junyu Lai
6ab0a5500d Merge "[FUI16] Expose setSubscriberId in NetworkAgentConfig as system API" am: bc1a11fdb2 am: d53184a4de am: bd6e9518e0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1556552

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If6e5747ccc97972a4c21058c600e72c5a3f3b61e
2021-01-29 23:38:56 +00:00
Junyu Lai
680e2d4f64 Merge "[FUI04] Refactor VpnInfo" am: 149add890e am: ba245e077f am: 55c1a77fea
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1537211

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Icfa9918e41fc3f952a23956108df4db449741364
2021-01-29 23:38:06 +00:00
Junyu Lai
3c48d0cf6f Merge "[VCN06] Support request background network" am: 2141aec60a am: 336c5d93a7 am: 4d9ef0fc1e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1553866

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I50867bc7cb21eb134f20af9ef55c44c2bd8962e9
2021-01-29 23:36:41 +00:00
Junyu Lai
bd6e9518e0 Merge "[FUI16] Expose setSubscriberId in NetworkAgentConfig as system API" am: bc1a11fdb2 am: d53184a4de
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1556552

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ifcaddb813f501065921e55b6e8a33269c1f4f95f
2021-01-29 23:22:35 +00:00
Junyu Lai
55c1a77fea Merge "[FUI04] Refactor VpnInfo" am: 149add890e am: ba245e077f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1537211

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Idee0985fa0feb2c3fd572c66c12a4ee5f0e236e7
2021-01-29 23:21:49 +00:00