Commit Graph

568045 Commits

Author SHA1 Message Date
Treehugger Robot
3eea8f3546 Merge "Move connectivity sources to packages/Connectivity" am: b249b941ee
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1706845

Change-Id: Id619f74f84699c8f63edad37beb63537b7c06b3d
2021-05-14 06:41:07 +00:00
Treehugger Robot
b249b941ee Merge "Move connectivity sources to packages/Connectivity" 2021-05-14 06:22:36 +00:00
Benedict Wong
b3f0495383 Merge "Custom network selection" am: bc3638ce5d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1706226

Change-Id: Idd12259974b19a20a6969a0afce14c4825492138
2021-05-14 04:45:44 +00:00
Benedict Wong
bc3638ce5d Merge "Custom network selection" 2021-05-14 04:22:03 +00:00
Cassie Wang
6e11df3fe7 Merge "Have the shell request AppSearch global query permission." am: f37a782378
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1704125

Change-Id: I17c5b35ac84d031ce259bb65ee49e4e619eab76f
2021-05-14 02:54:08 +00:00
Cassie Wang
f37a782378 Merge "Have the shell request AppSearch global query permission." 2021-05-14 02:36:27 +00:00
Benedict Wong
9028cac4fe Custom network selection
This change adds a basic prioritization framework in the VCN, and signal
strength thresholds for WiFi.

Bug: 188104094
Test: atest FrameworksVcnTests
Change-Id: Iee4e3dbecf1102ddc127a8c8daf08a00b6fccbbd
2021-05-13 18:57:05 -07:00
Joshua Duong
bc9360ea4e Merge "Use keymasterSwEnforcedUserAuthenticators if keymasterHwEnforcedUserAuthenticators is zero." am: 3b2decbb34
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705645

Change-Id: Iadbd63a4c99d148179b41be32a3862a2fcdd617c
2021-05-13 20:29:47 +00:00
Joshua Duong
3b2decbb34 Merge "Use keymasterSwEnforcedUserAuthenticators if keymasterHwEnforcedUserAuthenticators is zero." 2021-05-13 20:16:08 +00:00
Elliott Hughes
c881ac71b5 Merge "Remove a use of String16::remove." am: 0529640cc0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1704170

Change-Id: I70230cad27bf33d6b02022d28442686885724fb6
2021-05-13 19:19:01 +00:00
Elliott Hughes
0529640cc0 Merge "Remove a use of String16::remove." 2021-05-13 19:04:33 +00:00
Ken Chen
637d31088d Merge "[DO NOT MERGE] Revert "Reference unreachable netId from INetd"" am: 3c2cd1a33c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705391

Change-Id: I1662004b925d40bd84851ddef1d63654307e7862
2021-05-13 18:43:27 +00:00
Ken Chen
e2431f5328 [DO NOT MERGE] Revert "Reference unreachable netId from INetd" am: 4d9020efb5
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705391

Change-Id: I9735b2c50de8899ca7c856ee02ade2fa3ec1a357
2021-05-13 18:41:12 +00:00
Lais Andrade
777b5e12fe Merge "Use a fallback vibration effect for GESTURE_END" am: 12ffac178a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1675891

Change-Id: I512ba8ccfbaeafa4e8ac32ebfe9164a2b605f994
2021-05-13 18:37:32 +00:00
Remi NGUYEN VAN
3d97bd9e5e Move connectivity sources to packages/Connectivity
The service-connectivity sources should be in
packages/modules/Connectivity. Move them to
frameworks/base/packages/Connectivity, so that the whole directory can
be moved to the dedicated packages/modules/Connectivity git project.

Bug: 186628461
Test: m
Merged-In: I26d1a274058fa38763ad4f605549d880865b4d76
Change-Id: Ie0562db92ebee269b901926d763ae907bde61b98
2021-05-13 18:18:42 +00:00
Ken Chen
3c2cd1a33c Merge "[DO NOT MERGE] Revert "Reference unreachable netId from INetd"" 2021-05-13 17:59:00 +00:00
Lais Andrade
12ffac178a Merge "Use a fallback vibration effect for GESTURE_END" 2021-05-13 17:49:44 +00:00
Ken Chen
4d9020efb5 [DO NOT MERGE] Revert "Reference unreachable netId from INetd"
This reverts commit 601eb97832.

Reason for revert: Automerge conflict on sc-dev. The target file has been moved to other folder in sc-dev (ag/14516148). Revert this change and check-in again from AOSP bases on aosp/1706845.

Change-Id: I93a8bf4a3f59d789d88adceb3760c586b9951750
2021-05-13 17:40:51 +00:00
Ken Chen
2543a4d376 Merge "Reference unreachable netId from INetd" am: db64a7da1d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705386

Change-Id: I522103bab137e3c1c8941d3611ccd968fdfdd781
2021-05-13 16:30:10 +00:00
Ken Chen
db64a7da1d Merge "Reference unreachable netId from INetd" 2021-05-13 16:10:49 +00:00
Remi NGUYEN VAN
f3249af8c7 Merge "[NS04] Introduce Network Offers and their callbacks" am: daffcf97ef
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1556102

Change-Id: Ifcdc55f7b202b9fe1ea10c9546c07d4563e9988c
2021-05-13 15:35:10 +00:00
Lorenzo Colitti
836ffee197 Merge changes Ia5bc896c,I0c9406f4,I3108ee94 am: de0eb903cb
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705389

Change-Id: I30c22bae1e2df6497483fd863396f2abb6def278
2021-05-13 15:30:59 +00:00
Remi NGUYEN VAN
daffcf97ef Merge "[NS04] Introduce Network Offers and their callbacks" 2021-05-13 15:11:45 +00:00
Lorenzo Colitti
de0eb903cb Merge changes Ia5bc896c,I0c9406f4,I3108ee94
* changes:
  Make VcnTransportInfoTest pass on AOSP.
  Immediately redact VcnTransportInfo.
  Do not automatically redact TransportInfo objects.
2021-05-13 15:11:01 +00:00
Treehugger Robot
da769ac79d Merge changes If663677b,I387d90ea am: ea4a93a946
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1706425

Change-Id: I59eb38410465eed276c5744d5373b4ef84656f37
2021-05-13 14:36:47 +00:00
Treehugger Robot
ea4a93a946 Merge changes If663677b,I387d90ea
* changes:
  Fixed KeyGenParameterSpecTest
  Keystore 2.0 SPI: Fix NPE in getUniqueAliases.
2021-05-13 14:20:44 +00:00
Paul Hu
04d9298d48 Merge "Update mobile data preference getter/setter" am: 5a986ca45d
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1702486

Change-Id: Ieb72b4f0284d5439f62037b9d68da054f276120d
2021-05-13 14:07:56 +00:00
Paul Hu
5a986ca45d Merge "Update mobile data preference getter/setter" 2021-05-13 13:42:05 +00:00
Chalard Jean
28562ef63b [NS04] Introduce Network Offers and their callbacks
This patch introduces the concept of a network offer that
providers send to Connectivity to register for relevant
requests. This lets them see only requests that they can
hope to satisfy considering their capabilities and score
filters.

This is meant to replace the filtering mechanism currently
implemented by NetworkFactory. The reason for replacing
this mechanism is that the old mechanism does caps and
score filtering on the factory side, which requires these
two filters to be contextless and available system-wide,
including in separate processes from the system server.
These constraints severely limit and complexify in
particular what the score comparisons may look like. In
the past the score comparison was only integer-based,
making the code duplication not much of a problem, but as
this scheme is becoming unsustainable by spreading the
complexity of the selection across the entire stack, a
centralized mechanism is now necessary.

This patch only introduces the new objects and has CS
keep track of them, but does not actually use them yet.
Followup patches will implement the logic of calling
the offer callbacks.

Test: FrameworksNetTests NetworkStackTests FrameworksWifiTests
Bug: 167544279
Merged-In: Idec1fe8eb4ac6f562bf098e3dd470f11024d04f2
(clean cherry-pick)

Change-Id: Idec1fe8eb4ac6f562bf098e3dd470f11024d04f2
2021-05-13 13:20:43 +00:00
Remi NGUYEN VAN
78a1add7d9 Merge "Move net unit tests to packages/Connectivity" am: 5b48156498
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1706685

Change-Id: I86852c79cf06a3bc7b7ccaa18d83f70a2043b258
2021-05-13 11:32:36 +00:00
Anton Hansson
2a4b485cc8 Merge "Suppress reflection errors and dedupe flags" am: 9e1ca7acf7
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1588352

Change-Id: I2b61cb18103b008016761ecc032e8868107446bd
2021-05-13 11:29:17 +00:00
Lorenzo Colitti
34748be150 Make VcnTransportInfoTest pass on AOSP.
AOSP contains the core networking redaction changes, but not the
wifi redaction changes, so the tests that depend on wifi S
behaviour will not pass on AOSP.

Fix testApplicableRedactions by checking that the applicable
redactions are the same ones as returned by the underlying
WifiInfo object.

Fix testMakeCopyRedactForAccessFineLocation by testing the wifi
redaction code iff Build.VERSION.SDK_INT is S or later. This is
different from SdkLevel.isAtLeastS, because the latter returns
true in AOSP.

Bug: 183938194
Test: atest VcnTransportInfoTest
Change-Id: Ia5bc896c92be19f570638f8051492e0f2d7342f9
2021-05-13 20:24:20 +09:00
Lorenzo Colitti
1ad18702f1 Immediately redact VcnTransportInfo.
Redaction of NetworkCapabilities is changing from redacting at
parcel time to redacting immediately when makeCopy() is called.
Update VcnTransportInfo redaction accordingly.

Bug: 183938194
Test: atest VcnTransportInfoTest
Change-Id: I0c9406f426b66fd36b47d11799955def531c16ba
2021-05-13 20:24:20 +09:00
Lorenzo Colitti
3533c16720 Do not automatically redact TransportInfo objects.
Currently, NetworkCapabilities always redacts the TransportInfo
objects it contains whenever a defensive copy is made. This makes
it impossible to make a defensive copy on a TransportInfo
parcelled from another process without redacting it.

Stop redacting by default; instead rely on ConnectivityService
explicitly calling NetworkCapabilities' redacting constructor
when it returns a NetworkCapabilities object to an app via a
callback or synchronous call. This is currently done by
- createWithLocationInfoSanitizedIfNecessaryWhenParceled, which
  is called from callCallbackForRequest, getNetworkCapabilities,
  and getDefaultNetworkCapabilitiesForUser.
- getNetworkCapabilitiesWithoutUids, which is used when sending
  ConnectivityDiagnosticsManager callbacks. In this method,
  unconditionally redact all information, which is what the code
  did previously due to the default redaction setting for empty
  NetworkCapabilities objects being REDACT_ALL.

Bug: 183938194
Test: atest NetworkCapabilitiesTest
Test: atest FrameworksNetTests CtsNetTestCases HostsideVpnTests
Change-Id: I3108ee94cb0930958e071ba678c3554525b0db82
2021-05-13 20:24:19 +09:00
Remi NGUYEN VAN
5b48156498 Merge "Move net unit tests to packages/Connectivity" 2021-05-13 11:10:49 +00:00
Anton Hansson
9e1ca7acf7 Merge "Suppress reflection errors and dedupe flags" 2021-05-13 11:01:03 +00:00
paulhu
61c1b37d72 Update mobile data preference getter/setter
To satisfy OEM's requests, setting mobile data preference
should be by uid. Thus, update the getter/setter to
return/accept set of uids that need to apply mobile data
preference.

Bug: 171872461
Test: atest FrameworksNetTests
Change-Id: Id44efd2a6d820867f4405426c91e65b9ef155898
2021-05-13 10:35:29 +00:00
Paul Duffin
8b6cd2dfe1 Merge "Add media-module-sdk build target." am: a6e369bb32
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705354

Change-Id: I970914ee5cfb5771d2ada4fbc25842d015407fe6
2021-05-13 10:09:52 +00:00
Paul Duffin
a6e369bb32 Merge "Add media-module-sdk build target." 2021-05-13 09:48:42 +00:00
Anton Hansson
aa26cc10db Suppress reflection errors and dedupe flags
Bug: 168689341
Test: m frameworks-base-api-current-compat
Change-Id: Ied6452849ef994424500b56a042983b92ecc41f2
2021-05-13 10:27:20 +01:00
Remi NGUYEN VAN
1665a3d634 Move net unit tests to packages/Connectivity
Move the tests together with packages/Connectivity code, so both can be
moved to packages/modules/Connectivity together.

Also reorganize unit tests in a unit/ directory, as other tests
(integration/, common/ etc.) have been added in tests/net since they
were created. This makes the directory structure consistent.

Test: atest FrameworksNetTests
Bug: 187814163
Merged-In: I254ffd1c08ec058d594b4ea55cbae5505f8497cc

Change-Id: I254ffd1c08ec058d594b4ea55cbae5505f8497cc
2021-05-13 08:30:33 +00:00
Paul Hu
fe7e35ea07 Merge "Add RESTRICTED_ALLOWED_APPS setting" am: e6d2b4663e
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1689208

Change-Id: I93c004e7356559436c7dbd95716e52db8fc1ba0d
2021-05-13 05:54:31 +00:00
Paul Hu
e6d2b4663e Merge "Add RESTRICTED_ALLOWED_APPS setting" 2021-05-13 05:32:19 +00:00
Linzhao Ye
0e751cd213 Merge changes Id9a9451a,Idf113709 am: 03a24f50cc
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1702072

Change-Id: Ie027778a90deb5a3956f0e1dc9cbf462c9a4b50e
2021-05-13 04:53:17 +00:00
Linzhao Ye
03a24f50cc Merge changes Id9a9451a,Idf113709
* changes:
  Change the brackets in Persian keyboard layout.
  Change the brackets in Hebrew keyboard layout.
2021-05-13 04:33:11 +00:00
Treehugger Robot
ad73e362f0 Merge "Keystore 2.0 SPI: Silence warning about blocking calls to Keystore." am: fa8d51d5a6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1706447

Change-Id: I1e18b1b6c51ea0bb4c9db9623259161a75781f29
2021-05-13 02:11:32 +00:00
paulhu
5ee5670cc1 Add RESTRICTED_ALLOWED_APPS setting
This setting is OEM upstream requirement for third party apps
using restricted networks.

Bug: 185149952
Test: atests FrameworksNetTests
Change-Id: I5e16b46cf2935f38ee1e516bb8b85fa487cf9f61
2021-05-13 10:09:31 +08:00
Ken Chen
3ae939569e Merge "Add testVpnTypesEqual to verify consistency" am: 785dc4871c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1705385

Change-Id: I18b5716252efc4f7c33ec8263c09df1f9396d1fe
2021-05-13 02:05:37 +00:00
Ken Chen
d0ab30add0 Merge "Better log in createNativeNetwork" am: bd0ba5d94b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1704925

Change-Id: Ic8afb71d7ac099f6c492dda8f9f54a5da3c79649
2021-05-13 02:01:21 +00:00
Treehugger Robot
fa8d51d5a6 Merge "Keystore 2.0 SPI: Silence warning about blocking calls to Keystore." 2021-05-13 01:57:26 +00:00