Commit Graph

8522 Commits

Author SHA1 Message Date
TreeHugger Robot
ca4f0580fe Merge "Add public API and stub implementations for app integrity manager (service)." 2019-11-26 20:31:33 +00:00
Song Pan
75147d5967 Add public API and stub implementations for app integrity manager (service).
App integrity manager will accept rules from verifier and evaluate these rules
during install (and accept/reject the install accordingly). For more
information, see the linked bug (and the blocked bug).

Design doc: go/integrity-component-android-infra

Bug: 143689885
Change-Id: Ie965c6cc77987e06e9dea4be8fb49785a7bd08c4
Test: moving only
2019-11-26 18:38:17 +00:00
Roshan Pius
f7ea8f9d32 Revert "Add a new wifi protection level"
This reverts commit 73266f2f64.

Reason for revert: Wifi services no longer plan to be a separate
APK/process for mainline. Will instead become a jar loaded from Apex.

Bug: 144722612
Test: Device boots up & connects to wifi networks.
Change-Id: I234510b96ddd39f64f74eb0573963365f9ff5556
2019-11-25 21:00:00 -08:00
Roshan Pius
ac76d48454 Revert "Mainline wifi stack module"
This reverts commit 6f5338dd8f.

Reason for revert: Wifi services no longer plan to be a separate
APK/process for mainline. Will instead become a jar loaded from Apex.

Bug: 144722612
Test: Device boots up & connects to wifi networks.
Change-Id: I293e36973c4bdbd8bf9db2fcd78e61e6c38b39f4
2019-11-25 20:59:31 -08:00
TreeHugger Robot
276b49f758 Merge "Create empty PowerWhitelistManager." 2019-11-23 01:33:12 +00:00
TreeHugger Robot
153f66fb91 Merge "Fix "Allow the system AssetManager to be reinitialized for testing"" 2019-11-22 22:39:00 +00:00
Kweku Adams
e371b09fbf Create empty PowerWhitelistManager.
This is the first step in extracting the power whitelist from
DeviceIdleController. The whitelist will stay inside the JobScheduler
mainline module boundary, so all calls will have to be made through a
stable API. Eventually, all users of IDeviceIdleController will be
migrated to this interface.

Bug: 140141678
Bug: 141155196
Bug: 144864180
Test: atest PowerWhitelistTest
Change-Id: I8468e74ac8fe6611bfa957d4f5093c8d15be1299
2019-11-22 11:54:24 -08:00
Terry Wang
2cf38fe7e9 Merge "Add a new system service for app search project" 2019-11-21 22:43:08 +00:00
Terry Wang
ecc0d1b2c1 Add a new system service for app search project
Bug: 142567528
Test: manual
Change-Id: Iefb426383f94ec89c896065c798b22cfb2977bf3
2019-11-21 14:15:22 -08:00
Winson Chiu
1e05667111 Merge "Overlayable actor enforcement" 2019-11-21 21:46:47 +00:00
Winson
d9d1736767 Overlayable actor enforcement
Validates that the caller of an OverlayManager API that mutates state
is actually allowed to act on the target as defined in the target's
overlayable tag.

<overlayable name="MyResources" actor="namespace/name">

An actor is valid if any of the following is true:
 - is root/system
 - is the target overlay package
 - has the CHANGE_OVERLAY_PACKAGES permission and an actor is not defined
 - is the same package name as the sole resolved Activity for the actor specified
     in the overlayable definition, with only pre-installed, namespaced actors
     currently supported

Bug: 119442583
Bug: 135052950

Test: atest SystemConfigNamedActorTest
Test: atest com.android.server.om

Change-Id: If56b9e8366852eaef84f6bb25c3e6871eaa3f219
2019-11-21 12:01:41 -08:00
TreeHugger Robot
2f6c5fe32f Merge changes from topic "broadcast_multiple_perm"
* changes:
  AndroidKeyStoreProvider: Add @throws documentation
  RemoteException: Add @throws documentation
  Context: Rename Context.sendBroadcastMultiplePermissions
2019-11-21 06:28:10 +00:00
TreeHugger Robot
dfe69d9e2d Merge "Move UserTypeDetails & UserTypeFactory to services" 2019-11-21 00:43:29 +00:00
Roshan Pius
a2baf58e26 Context: Rename Context.sendBroadcastMultiplePermissions
Renaming based on API council feedback. Leaving the old API as @hide
since there are other modules in platform using the old API.

Bug: 144793100
Test: Compiles
Change-Id: Id3fd01da3b4163d186cf9651a5b2b82c18859239
2019-11-20 14:47:43 -08:00
Jordan Liu
337e999d5c Merge "Remove unneeded @RequiresPermission annotation" am: 0a1b47573e am: 277ea3584f
am: ec296c8e53

Change-Id: I2e8d0718a56bcc205f3fa93244b0ee9d8b367707
2019-11-20 14:37:17 -08:00
Jordan Liu
ec296c8e53 Merge "Remove unneeded @RequiresPermission annotation" am: 0a1b47573e
am: 277ea3584f

Change-Id: I83c853e4512261f0c94432659a1b7a749d6fd32a
2019-11-20 14:29:40 -08:00
Jordan Liu
277ea3584f Merge "Remove unneeded @RequiresPermission annotation"
am: 0a1b47573e

Change-Id: I47d83e0d224cb9840b326212f84c83a8e16c1a85
2019-11-20 14:22:03 -08:00
Makoto Onuki
2dfdf1a4cf Merge "Add Context.createContextAsUser()" am: 63d5e4a0b9
am: 056b8f00b7

Change-Id: I703b0234c75f91ad548a0c431277d684212e0586
2019-11-20 14:11:19 -08:00
Jordan Liu
0a1b47573e Merge "Remove unneeded @RequiresPermission annotation" 2019-11-20 22:04:20 +00:00
Makoto Onuki
056b8f00b7 Merge "Add Context.createContextAsUser()"
am: 63d5e4a0b9

Change-Id: I022daba2bc9234ffe7b7fa760942a58852e406b3
2019-11-20 14:04:20 -08:00
Treehugger Robot
63d5e4a0b9 Merge "Add Context.createContextAsUser()" 2019-11-20 21:53:01 +00:00
Ryan Mitchell
3286a5f61c Fix "Allow the system AssetManager to be reinitialized for testing"
The logic was incorrect and prevented the test from reinitializing
the system assets.

Bug: 136085555
Test: tradefed.sh
Change-Id: If95417d29a8a1110560b670900a53ff3db2604a2
2019-11-20 11:57:04 -08:00
TreeHugger Robot
aa26bed5c8 Merge "Remove legacy idmap binary" 2019-11-20 16:41:38 +00:00
Makoto Onuki
9432f7d43c Add Context.createContextAsUser()
Without it, apps (mainline modules) will need to use createPackageContext...,
which is a bit painful.

Bug: 142472686
Test: atest android.content.cts.ContextTest#testCreateContextAsUser
Change-Id: Id640e03862462724df1a4a3101f0b08faafba22f
(cherry picked from commit b844001d6a)
Merged-in: Id640e03862462724df1a4a3101f0b08faafba22f
2019-11-19 20:51:04 -08:00
Ryan Mitchell
a12b9e0c3f Merge "Allow the system AssetManager to be reinitialized for testing" 2019-11-20 04:01:11 +00:00
TreeHugger Robot
5c407dc002 Merge "Remove @SystemApi annotation for an overriding method" 2019-11-20 00:22:32 +00:00
Patrick Baumann
ff21f7b085 Merge "DO NOT MERGE Avoids deadlock when applying preferred activities" am: 35dd014a79
am: 92269e5ef8

Change-Id: I6d95f0bbdaa146c4d96f8b8c5f715ef2053074be
2019-11-19 16:20:20 -08:00
Patrick Baumann
92269e5ef8 Merge "DO NOT MERGE Avoids deadlock when applying preferred activities"
am: 35dd014a79

Change-Id: I9b4646c9c0674380e37eea44a226b1b279b53f6b
2019-11-19 16:05:31 -08:00
Hall Liu
ae63546d19 Merge commit '1d7a53da981b7d4281c58af7eb9b150163b344a6' into manual_merge_1d7a53da981b7d4281c58af7eb9b150163b344a6
am: dab3711435

Change-Id: Ib75482a87545f7743f0049c8e51c354d2294c2af
2019-11-19 15:12:28 -08:00
Ryan Mitchell
260d13b27d Allow the system AssetManager to be reinitialized for testing
ResourcesPerfWorkloads replays record resources calls for 1P and 3P
apps. The recordings use private resource ids. Since private
resources ids can change between builds, the replay must have the
ability to use a stable version of framework resources with the
correct resource ids.

Bug: 136085555
Test: atest ResourcesPerfWorkloads
Change-Id: I46297e355ed6347ce8063e7f1c26708f28faacc8
2019-11-19 14:05:16 -08:00
Patrick Baumann
3fa8853331 DO NOT MERGE Avoids deadlock when applying preferred activities
Prior to this change, we were resolving the mime type of a given intent
while holding the package lock. With this change, we instead rely on the
preferred-activity declaration to define the mime type if it's
important, removing need for an activity manager service call and the
potential for deadlock.

Fixes: 143105100
Test: Manual; sideload to /system/etc/preferred-apps/ and reset app preferences
Change-Id: Ia87b7ecbd7987ef654fb0fc2bda942cd6a9c00a7
2019-11-19 21:43:48 +00:00
Hall Liu
dab3711435 Merge commit '1d7a53da981b7d4281c58af7eb9b150163b344a6' into manual_merge_1d7a53da981b7d4281c58af7eb9b150163b344a6
Change-Id: Ie08d8bb30e48a9e7ade85334c6195a791ecc0d9b
2019-11-19 12:37:24 -08:00
Jordan Liu
31a4da61b5 Remove unneeded @RequiresPermission annotation
Fixes: 144360225
Test: no change to behavior
Change-Id: I7b3ab01c4d232013dcc19de32cc8e2cee9b8cb5a
2019-11-19 11:47:53 -08:00
Artur Satayev
785d3a03b9 Merge "Add @UnsupportedAppUsage annotations for greylist." 2019-11-19 15:05:51 +00:00
Artur Satayev
751e55114c Add @UnsupportedAppUsage annotations for greylist.
go/cleanup-greylist-txt

These have already been greylisted, however due to bugs/omissions in the tooling have been kept in go/greylist-txt instead of being annotated in the code.

This is partial merge of aosp/Id6c1f5e403a0e66edb1102ee45f3bf19f244fb09. Telephony greylist cleanup has been done separately. Note that annotations outside of frameworks/base/ have been merged from AOSP.

Bug: 137350495
Test: m
Exempt-From-Owner-Approval: merge
Change-Id: I015c466e8b69cc0fed5e9d394ba865aad11d8ba6
2019-11-19 15:05:35 +00:00
Jiyong Park
1620457e34 Remove @SystemApi annotation for an overriding method
Context.registerReceiverForAllUsers are already marked as @SystemApi.
The same method in ContextWrapper overriding it doesn't need to be
annotated as such. In fact, that API is even not recorded in
system-current.txt.

Bug: 144424011
Test: atest CtsSystemApiAnnotationTestCases
Change-Id: I60890104bf20a2c674edd91ec6b487cca1b4e37b
2019-11-19 22:48:36 +09:00
Mohammad Samiul Islam
7da3588356 Merge "Allow staging multiple session with non-overlapping packages (apk-only)" 2019-11-19 12:03:51 +00:00
Ilya Matyukhin
d6b829939a Merge "Implemented and integrated AuthService" 2019-11-19 02:03:13 +00:00
TreeHugger Robot
ce934c7d78 Merge "Removed UserInfo.FLAG_MASK_USER_TYPE, it's not used anywhere anymore" 2019-11-18 23:24:54 +00:00
Bookatz
dffffc08ae Move UserTypeDetails & UserTypeFactory to services
These two classes should be in service side, i.e.
frameworks/base/service.

Test: atest com.android.server.pm.UserTests
Bug: 142151520
Change-Id: Idcd62ce4469bb194a16fc9ba932178fdd6fe50e5
2019-11-18 14:50:49 -08:00
Hall Liu
1d7a53da98 Merge changes from topic "mainline4"
* changes:
  Add new API for Telecom to send phone state
  Minor style correction to avoid merge conflict
  non-mainline telephony related AIDL refactor/decoupling
2019-11-18 22:31:27 +00:00
Ilya Matyukhin
e4675b3067 Implemented and integrated AuthService
AuthService in its current form is a thin wrapper around
BiometricService. It initializes BiometricService in onStart();
registers fingerprint, face, and iris authenticators; and forwards all
of the incoming calls to the corresponding methonds in BiometricService.

The next step will be to move non-biometric related functionality from
BiometricService to AuthService, and turn BiometricService into a module
with a stable API.

Bug: 141025588
Test: atest AuthServiceTest
Test: atest BiometricServiceTest
Test: BiometricPrompt works in BiometricPromptDemo
Change-Id: Ia861b7c2d80bfca386c3e0b44ec35b4aca3b0ffc
2019-11-18 22:10:50 +00:00
Chen Xu
501d21c629 Merge "add a new telephony protection level" am: cd953e939f
am: 2d98a66b18

Change-Id: Ie07cbd4d8c8350668a5d534fef9f1bd4863e43ab
2019-11-18 11:18:57 -08:00
Chen Xu
2d98a66b18 Merge "add a new telephony protection level"
am: cd953e939f

Change-Id: Ie275baf92a865fe1dc5855b00e49944d2598e4b4
2019-11-18 11:16:00 -08:00
Chen Xu
da02e07b92 add a new telephony protection level
for oems which take telephony mainline module, all telephony related
apks will be signed with non-platform certificate. that said apks won't
be able to grant platform signature permission. Solution is to add a new
telephony protection level.

Bug: 141479803
Test: cts & manual
Change-Id: Ib3be016080d42fd76e7c131f4e44d815ce431e6e
(cherry picked from commit 45c183d201)
Merged-in: Ib3be016080d42fd76e7c131f4e44d815ce431e6e
2019-11-17 17:49:41 -08:00
Jeff Sharkey
eca95ef9e8 Merge changes from topic "nov15"
* changes:
  Expand ContentProviderOperation support of extras.
  Extend insert/update/delete to provide extras.
  Query arguments for grouping, other SQL clauses.
2019-11-16 04:20:10 +00:00
Chen Xu
8eb62f9485 non-mainline telephony related AIDL refactor/decoupling
1. decouple IOnSubscriptionChangedListener AIDL from telephonyMainline
2. other refactor. moving APIs which will not be included in
telephony mainline to frameworks/base/core/java/android/telephony.
Moving internal classes like AIDL which will not be included in
telephony mainline to
framework/base/core/java/com/android/internal/telephony

Bug: 140908357
Test: Build & unit test
Change-Id: I9413ef758cceadd251d03f3b5ea1054cc48ef044
Merged-In: I9413ef758cceadd251d03f3b5ea1054cc48ef044
2019-11-15 18:02:40 -08:00
Jeff Sharkey
243d5f197c Expand ContentProviderOperation support of extras.
Now that we allow extras in more ContentProvider calls, we should
also allow CPO to define and pass those extras into a provider.  We
recently added flexible utility methods like withExtraBackReference(),
so this change starts passing those values to insert, update, delete,
and query.

Bug: 131643582
Test: atest CtsContentTestCases
Change-Id: I4a445c061bbd84f45bdb80d336a2d0928b7fbe9c
2019-11-15 14:11:42 -07:00
Jeff Sharkey
e9fe152f31 Extend insert/update/delete to provide extras.
A few releases ago we added ContentResolver.QUERY_ARG_* constants
to query() as a new best-practice that will help wean us off raw
SQL arguments.  (For example, a provider could add their own
custom arguments like QUERY_ARG_INCLUDE_PENDING to cause the query
to reveal pending items that would otherwise be hidden.)  This
change expands update() and delete() to accept those arguments.

This change also expand insert() to accept extras too, as part of
preparing to support an upcoming MediaProvider feature that will let
apps place new media "adjacent" to an existing media item.  (Sending
that adjacent item through extras is cleaner than trying to send it
through escaped query parameters.)

Bug: 131643582
Test: atest CtsContentTestCases
Change-Id: I436296155b9b5f371b4cbe661feaf42070285fcc
2019-11-15 13:46:31 -07:00
Adam Bookatz
b9a57da94c Merge "Introduce user types" 2019-11-15 19:15:37 +00:00