Commit Graph

1569 Commits

Author SHA1 Message Date
TreeHugger Robot
5eb9c8fada Merge "Store conversation requirement in a setting" into rvc-dev 2020-04-07 03:47:02 +00:00
Julia Reynolds
e24faa2c86 Store conversation requirement in a setting
So we can show it in developer options. Also fix a bug
where the setting wasn't being respected in systemui.

Test: atest
Bug: 152907434
Change-Id: I1eaed93a0c8a1ec4486c7072972e2f924402bb94
2020-04-02 16:28:40 -04:00
Soonil Nagarkar
c4f8716720 Fix up LocationRequest and ProviderRequest
-Use more idiomatic and efficient parceling
-Cleanup LocationRequest a bit

Bug: 151026407
Test: presubmits
Change-Id: I3865421a128417a5096e39ee110139a13ab9ab3b
2020-04-01 11:06:12 -07:00
TreeHugger Robot
c6f4f74723 Merge "V4 uses V2 digest if V3 is not available." into rvc-dev 2020-03-25 01:36:01 +00:00
Alex Buynytskyy
6b7efbc4b9 V4 uses V2 digest if V3 is not available.
Test: atest PackageManagerShellCommandIncrementalTest
Bug: b/151240006
Change-Id: I242b599e434880ce218537574e879e9436e5d3da
2020-03-24 14:34:52 -07:00
Joe Onorato
8006029ec9 Address API Council comments for ProtoOutputStream
Bug: 148011305
Bug: 148966916
Test: m && m offline-sdk-docs
Change-Id: I0aeeb74329a90706999d6103b7da2e239f4a369e
2020-03-23 20:41:24 -07:00
TreeHugger Robot
87500a84a4 Merge "Make Log.isLogagble @FastNative" into rvc-dev 2020-03-23 20:25:39 +00:00
Makoto Onuki
8e81742dc0 Make Log.isLogagble @FastNative
This CL doens't change println_native() because:
- To avoid potential risks (jank?) because it's kind of late in the RVC
cycle.
- The JNI overhead is unlikely to be a major problem in logging. If apps
are making *that* many log calls, that itself would be a bigger
problem.

Test: treehugger / boot
Bug: 152217649
Change-Id: I86aeb62b217e5331e6bbd02a0ba592fd050a41b2
2020-03-23 17:19:05 +00:00
Jason Chiu
8234820115 Enable the feature flag for contextual home v2
Bug: 149274976
Test: rebuild
Change-Id: Id3af8c6cae731222236a510a10cbeb9937004862
2020-03-23 17:20:56 +08:00
Ruslan Tkhakokhov
3a0df8a06c Merge "Enable SETTINGS_DO_NOT_RESTORE_PRESERVED by default" into rvc-dev 2020-03-18 11:48:15 +00:00
TreeHugger Robot
173eb0db9b Merge "[framework] Extract v3 digest for v4 checking correctly" into rvc-dev 2020-03-17 21:22:35 +00:00
Yurii Zubrytskyi
087cf41e51 [framework] Extract v3 digest for v4 checking correctly
Use the same ordering of digest algorithms as the apksigner and
the general v3 checking do.

Test: adb install --incremental <apk> with v4 signature
Bug: b/151241461
Change-Id: I5c4c8339d7fd2ba127bd0f453efc9c04a8be7ac7
2020-03-17 09:49:08 -07:00
Rajeev Kumar
7cff642925 Merge "Revert "Enable settings_tether_all_in_one by default"" into rvc-dev 2020-03-17 03:09:23 +00:00
Zhen Zhang
e373051f01 Revert "Enable settings_tether_all_in_one by default"
This reverts commit ab42095409.

Reason for revert: b/151579796, b/151624169

Bug: 151579796
Change-Id: Ic398efd54e667a7f250ce0e7ac5082502a40078a
2020-03-16 19:21:21 +00:00
Khaled Abdelmohsen
2aee73b4e6 Close file streams
This is mainly refactoring, without any new logic.

Bug: 148005911
Test: Refactoring, presubmits are sufficient
Change-Id: I3b9b35f4a952edc04357a2c1b265b1d0f346d515
2020-03-15 23:29:33 +00:00
Khaled Abdelmohsen
2c89227525 Merge "Support multi apk stamp verification" into rvc-dev 2020-03-14 07:23:34 +00:00
Khaled Abdelmohsen
f6b1e8c3f6 Support multi apk stamp verification
Bug: 148005911
Test: atest FrameworksCoreTests:SourceStampVerifierTest
Change-Id: Iffab565a03ae57c469784baa12bec9cd130e69a1
2020-03-14 00:23:56 +00:00
Alex Buynytskyy
f5e605a00c Updated v4 signature processing.
Passing to libincfs.so.
Obtaining and verifying, including v3 digest check.

go/apk-v4-signature-format

Test: atest PackageManagerShellCommandTest
Bug: b/151241461
Change-Id: Id61f5716b9f9b55d6ab1ebca5a7ecb1c6e54570a
2020-03-13 15:13:25 -07:00
Khaled Abdelmohsen
39bad6c991 Change source stamp verifier outcome
Modify source stamp verifier to produce non-present stamps when
receiving an error while reading the stamp file in an APK.

Bug: 148005911
Test: atest FrameworksCoreTests:SourceStampVerifierTest
Change-Id: I7682f51761e60b4236424cf2cdb6119f53259ab0
2020-03-13 18:56:21 +00:00
Ruslan Tkhakokhov
2b5cd2d0fb Enable SETTINGS_DO_NOT_RESTORE_PRESERVED by default
Bug: 144838882
Test: 1. CtsBackupTestCases
      2. CtsBackupHostTestCases
      3. GtsBackupTestCases
      4. GtsBackupHostTestCases
Change-Id: I13a7e5d3b1c56a4c2987ba565f82c1adeb6f4893
2020-03-12 14:45:04 +00:00
Zhen Zhang
ab42095409 Enable settings_tether_all_in_one by default
Enable the flag to show the new tethering settings UI.

Bug: 147675042
Test: manually test.

Change-Id: Idba65c588c08b8474aba97feeca1ed234c1c73ca
2020-03-05 15:14:26 -08:00
Khaled Abdelmohsen
e2ab8ed00e Merge "Create source stamp verifier in platform" into rvc-dev 2020-03-03 21:10:50 +00:00
Khaled Abdelmohsen
8ce84c8567 Create source stamp verifier in platform
Bug: 148005911
Test: atest FrameworksCoreTests:SourceStampVerifierTest
Change-Id: Ibdaedf0355f5dd3537a425a031e298b710aae9f7
2020-03-03 17:16:56 +00:00
Arc Wang
d03c6ac27e Merge "[Wi-Fi] Default enable WifiTracker2 feature flag" into rvc-dev 2020-03-03 01:58:05 +00:00
TreeHugger Robot
0b81d6b2f9 Merge "Refactor isSupportedSignatureAlgorithm" into rvc-dev 2020-03-02 21:00:48 +00:00
Khaled Abdelmohsen
f10fc7a5e7 Refactor isSupportedSignatureAlgorithm
Bug: 148005911
Test: N/A
Change-Id: I33250657fb233e49988a3e18746badd937a91746
2020-03-02 19:08:26 +00:00
Arc Wang
8de1caf9e8 [Wi-Fi] Default enable WifiTracker2 feature flag
After the feature flag default enabled, Wi-Fi Settings
will use it in Wi-Fi picker / Wi-Fi detal / Saved Wi-Fi network
activities.

Bug: 70983952
Test: compile
Change-Id: Ia88ecd7b8f9eb5962c18c772cc130dc1153bfa1e
2020-03-02 15:38:06 +08:00
Michael Wachenschwanz
240896281b Throw ProtoParseException for incomplete values
Reading a corrupted stream/file could cause an infinite loop while
reading values. Throw an exception if unexpectedly reached the end of
the stream.

Bug: 150192344
Test: atest ProtoInputStreamTests
Change-Id: Ie660545152ba821be0c371dd1e3bf7235372bc6d
2020-02-27 17:44:14 -08:00
Kevin Hufnagle
c027fa0d0d docs: Fix spelling of "environments"
Test: make ds-docs

Bug: 150187311
Change-Id: Id8ecd7a7e4014e8256b60d6ce2f2f1085ee9cdfb
2020-02-25 17:50:14 +00:00
Al Sutton
feebe8143e Revert "Add feature flag for "no data" backup calls"
This reverts commit 27c64a3bed.

Reason for revert: The GMSCore code to handle the flag will be part of DP2 and so we can remove the flag ahead of the cut.

GMSCore CL Status; https://cl-status.corp.google.com/#/summary/gmscore_prod/291378558
GMSCore Calendar; http://go/gms-schedule

Bug: 147481066
Test: m -j RunBackupFrameworksServicesRoboTests
Change-Id: I4159e064e739c6f366063c7fadd7cca40a7f07d9
2020-02-21 10:49:57 +00:00
Rubin Xu
1480ce7b87 Support security logging on org-owned managed profile devices
When security logging is enabled on org-owned profile devices,
Security events will be redacted to preserve privacy on the personal
profile as follows:

* TAG_ADB_SHELL_CMD
  Shell command will be redacted.

* TAG_MEDIA_MOUNT
* TAG_MEDIA_UNMOUNT
  The media's volume name will be redacted.

* TAG_APP_PROCESS_START
* TAG_CERT_AUTHORITY_INSTALLED
* TAG_CERT_AUTHORITY_REMOVED
* TAG_KEY_GENERATED
* TAG_KEY_IMPORT
* TAG_KEY_DESTRUCTION
* TAG_KEY_INTEGRITY_VIOLATION
  Only events happening inside the managed profile will be returned
  to the admin.

Bug: 148437300
Test: atest FrameworksServicesTests:DevicePolicyManagerTest
Test: atest FrameworksServicesTests:SecurityEventTest
Test: atest FrameworksCoreTests:EventLogTest
Test: atest com.android.cts.devicepolicy.MixedDeviceOwnerTest#testSecurityLoggingWithSingleUser
Test: atest com.android.cts.devicepolicy.MixedDeviceOwnerTest#testSecurityLoggingWithTwoUsers
Test: atest com.android.cts.devicepolicy.MixedDeviceOwnerTest#testSecurityLoggingEnabledLogged
Test: atest com.android.cts.devicepolicy.OrgOwnedProfileOwnerTest#testSecurityLogging

Change-Id: I2e52229a3163b3e0dc3d80d71700023394d84587
2020-02-20 15:47:29 +00:00
Sudheer Shanka
a43148216a Add LongSparseArray.removeIf(Predicate).
Fixes: 149648797
Test: atest core/tests/coretests/src/android/util/LongSparseArrayTest.java
Change-Id: Ib7e73dcfe8be1dc1f3af577f30da7ebd5950d42a
2020-02-19 18:44:10 -08:00
Abhijeet Kaur
01f58baf57 FUSE settings flag on by default
Make Settings UI feature flag's default value consistent with
default value of FUSE flag (as it is now on by default).

Test: Settings->Feature Flags->settings_fuse shows true (expected
default value)

Change-Id: I296063af08455fbcdf0442388fae566a1a0e6372
2020-02-17 11:33:54 +00:00
Yi-Ling Chuang
e2b34e433f Add a feature flag for contextual home v2.
Bug: 143055685
Test: rebuild
Change-Id: I6ab53dc05a07aa8fc4cadd9b555d049fd42c7315
2020-02-13 18:05:38 +08:00
Alex Buynytskyy
780d2bb75d Merge "v4 signing schema parsing and verification." 2020-02-12 19:19:06 +00:00
Alex Buynytskyy
036864b62c v4 signing schema parsing and verification.
v4 is a streaming add-on to the existing v2/v3 schemas.

Flow:
- APK is signed with v2/v3 and v4 signature blocks,
- on installation, v4 signature bytes are stored next to the APK in
hidden block,
- on each read from APK, kernel verifies the v4 signature using
fs-verity-like code,
- on parsing/verification, we extract certificates from kernel and
compare them with certificates extracted from v2/v3 signature block.

By doing this we are making sure that v4 signature is produced by developer and original APK bytes are not changed.

Test: atest PkgInstallSignatureVerificationTest
Bug: b/136132412 b/133435829
Change-Id: Ia2a56c82c9864bf65e1338700dfe51abf6800deb
2020-02-12 09:46:06 -08:00
Sunny Shao
c83401dbc5 Add a new feature flag for Settings Schedules
Fixes: 148995400
Test: compilation
Change-Id: Id54eb51068ddf7b1a8fbbf535c7e0e86d1c9b5da
2020-02-11 17:48:22 +08:00
Alex Buynytskyy
02975de36f Addressing commens in ag/10265340.
Test: comments only
Change-Id: Ia3f786e89614c5a184d4c567baaf98e99c2af21a
2020-02-06 20:44:27 -08:00
Alex Buynytskyy
07674063ef ApkSignatureVerifier refactor.
Unifying multiple code paths.

Test: atest PkgInstallSignatureVerificationTest
Bug: b/136132412 b/133435829
Change-Id: I26612ad944ba34b64599a4148b6528ede31f3d11
2020-02-06 14:58:31 -08:00
Automerger Merge Worker
3e04f5af27 Merge "Avoid a @Nullable Boolean" am: 81a42af40d am: fd9c242128 am: 0db1f949da
Change-Id: Iae09c0c6e0d0b8cc9018b811c658d7d73e8a729b
2020-02-06 09:24:58 +00:00
Automerger Merge Worker
fd9c242128 Merge "Avoid a @Nullable Boolean" am: 81a42af40d
Change-Id: I5cf10a143bba4351efa2ea22fc5ccddb732f3044
2020-02-06 08:52:00 +00:00
Tej Singh
e86dab7a6a Move StatsLog.java to fw-statsd.jar
Test: atest GtsStatsdHostTestCases
Bug: 146578693
Change-Id: I7244c6099d16c5c7da14060a1a5fa0c866199754
2020-02-05 15:02:49 -08:00
Neil Fuller
b2d0306a00 Avoid a @Nullable Boolean
To avoid a @Nullable Boolean one method has been split into two. After
some changes in the last release this also removes an optional parameter
from the two new methods as it is now always null.

Bug: 148450671
Test: treehugger
Change-Id: I83be9647943c16ae30af4f8d032db428af1ad5fc
2020-02-05 17:13:31 +00:00
Jonathan Nguyen
a0e6de15df Update StatsLogProcessor to handle BinaryPushStateChanged
Also changed StatsLog to call write() instead of the hard coded function
in StatsService.

Test: gts-tradefed run gts-dev --module GtsStatsdHostTestCases
Change-Id: I26171fa4cfc877e1e179b74ec8076d964aff8548
2020-02-04 20:09:26 -08:00
Muhammad Qureshi
c5b609e6b0 Don't extend StatsLogInternal
Remove StatsLogInternal extension from StatsLog

Bug: 145952197
Test: m
Change-Id: Icd8e87315178f3b73f3ff8da07d355e29d297e7e
2020-02-04 11:25:16 -08:00
Shawn Lin
f2bfaebb94 Merge "Make WmDisplayCutout support waterfall and long edge cutout" 2020-02-04 06:59:25 +00:00
Muhammad Qureshi
e2b2432bc6 Use FrameworkStatsLog instead of StatsLog
As part of statsd becoming a Mainline module in R, autogenerated
StatsLog.write() calls are going away and replaced by
*StatsLog.java
that is autogenerated for each module.
This CL replaces some usages of StatsLog with
FrameworkStatsLog.

Bug: 145952197
Test: m
Change-Id: Iaa2db34a7be4c3215f62cc36661ba8ac81656baa
2020-02-03 09:17:40 -08:00
Zhen Zhang
7f5b5d18c5 Add a feature flag for the new tether settings UI
The default value of the flag is false.
Bug:148220934
Bug:148182953
Test: Build successfully.

Change-Id: I63bcf1afe68e42759cb1c73655bd7561fe180fab
2020-02-02 15:15:38 -08:00
TreeHugger Robot
1320c7b707 Merge changes I259a3f41,Id309a941
* changes:
  Guard the preserve settings logic in SettingsBackupAgent with a flag
  Do not restore settings marked as preserved in SettingsBackupAgent
2020-02-02 16:28:38 +00:00
Automerger Merge Worker
8311aef869 Merge "Tidy up libcore.timezone APIs" am: 8e0e0e8535 am: 0769745f70 am: 5075b7014b
Change-Id: I3a8f7fba7c7c84b6f248a5d500b157c3412eaafc
2020-01-31 16:32:04 +00:00