Commit Graph

7671 Commits

Author SHA1 Message Date
TreeHugger Robot
b4a5cf74b3 Merge "Add uid information in PackageListObserver" 2019-03-13 05:45:34 +00:00
TreeHugger Robot
c00ee56966 Merge "Revert related work of extractNativeLibs default flip" 2019-03-12 22:40:28 +00:00
Victor Hsieh
543059895f Revert related work of extractNativeLibs default flip
... in order to remove unnecessary code.

9e4da717 Revert "Flip default of extractNativeLibs if targets Q+"
fe693a07 Revert "Fix default of extractNativeLibs in parseBaseApplication"
86e2783d Revert "Partial revert to not flip the default of extractNativeLibs"

Test: atest CtsDynamicLinkerTestCases
Bug: 128335904
Change-Id: I0e43608a76b3891e84c1622c7a98e2a1dab91985
2019-03-12 10:28:12 -07:00
TreeHugger Robot
fbdd7930a0 Merge changes I72e979ce,I183b8a48
* changes:
  Add @IntDef for status of committed rollback.
  Use test stubs for RollbackTests, not system stubs.
2019-03-12 16:25:25 +00:00
TreeHugger Robot
e927626ad6 Merge "Address API review for SessionInfo, LauncherApps" 2019-03-12 14:44:53 +00:00
Richard Uhler
a4b70300e4 Add @IntDef for status of committed rollback.
Per API council request.

Bug: 127282563
Test: atest RollbackTest
Change-Id: I72e979ce3978c72a0783b44a044ad536b35ee09d
2019-03-12 12:36:03 +00:00
Richard Uhler
8a9774550d Use test stubs for RollbackTests, not system stubs.
Adds @TestApi for all system apis needed for RollbackTests.

Removes @SystemApi for RollbackManager.expireRollbackForPackage and
RollbackManager.reloadPersistedData, which were always intended to be
used solely for testing.

Bug: 127282563
Test: atest RollbackTest StagedRollbackTest
Change-Id: I183b8a484b4a08f36fc19d64241ab408d28c64ca
2019-03-12 12:14:37 +00:00
TreeHugger Robot
fe470d5fe6 Merge "Fix checkstyle error in PackageRollbackInfo." 2019-03-12 11:10:22 +00:00
TreeHugger Robot
10b249f57e Merge "ServiceInfo: Add a new foreground service type for MediaProjection." 2019-03-12 10:26:37 +00:00
TreeHugger Robot
f19439cc68 Merge "Make Resources#getAttributeSetSourceResId public" 2019-03-12 01:46:35 +00:00
TreeHugger Robot
519acc37cd Merge "Partial revert to not flip the default of extractNativeLibs" 2019-03-11 23:37:05 +00:00
Chenbo Feng
de8e3b7931 Add uid information in PackageListObserver
The uid information of a removed package cannot be retrieved by the
packageName anymore once it is removed. So it would be useful to provide
the uid of removed package in the onPackageAdded and onPackageRemoved
method of the PackageListObserver. This modification helps simplify the
design in PermissionMonitor.

Bug: 125396053
Test: dumpsys netd trafficcontroller

Change-Id: I2bd4bdf924687960a4fa3a47235bae68d885e445
2019-03-11 16:11:16 -07:00
Victor Hsieh
0faa8012ad Partial revert to not flip the default of extractNativeLibs
The original changes are 4e54b521 and 12dd9cd4.

Test: atest CtsDynamicLinkerTestCases
Bug: 124353586
Bug: 112037137
Bug: 128335904
Change-Id: Ie55bc735aebcf33d1561b5c225a8bac8d68e85e2
2019-03-11 12:58:56 -07:00
Richard Uhler
3d61846622 Fix checkstyle error in PackageRollbackInfo.
Test: builds.
Change-Id: I9ecbefbb3261c72a15bdc826af0a90b4fa4fe8ef
2019-03-11 15:18:08 +00:00
Narayan Kamath
06265a3b9b ServiceInfo: Add a new foreground service type for MediaProjection.
Test: make
Bug: 124753835
Change-Id: I328a03abc73d1abb523cd51334b57dabb9423669
2019-03-11 12:27:12 +00:00
Shafik Nassar
34b0c44a5a Merge "API cleanup: add NonNull annotation to Rollback API" 2019-03-11 11:44:46 +00:00
shafik
92ea53f448 API cleanup: add boolean param to setEnableRollback
Mark PackageInstaller.SessionParams#setEnableRollback() as @removed and
@deprecated.
Add PackageInstaller.SessionParams#setEnableRollback(enable).
Replace old API usages in RollbackTestUtils with the new API.

Also, add PackageInstaller.SessionInfo#getEnableRollback().

Fixes: 127282838
Test: atest RollbackTest
Change-Id: I696680207be5ac06560d2abb525f91a100301b4c
2019-03-11 09:48:54 +00:00
TreeHugger Robot
7233ef9c09 Merge "Fix getAttributeSetSourceResId to AttributeSet created from null." 2019-03-09 03:51:55 +00:00
Aurimas Liutikas
02d7f45afa Fix getAttributeSetSourceResId to AttributeSet created from null.
Xml.asAttributeSet with a null returns non XmlBlock.Parser type
object.
This fixes the existing test that broke due to my changes to
LayoutInflater.

Test: atest CtsViewTestCases:LayoutInflaterTest
Change-Id: Ib10e07ef3814c5570a6d2bd334481f2e26bb3d3e
2019-03-08 15:29:09 -08:00
Aurimas Liutikas
29a90d6b4b Make Resources#getAttributeSetSourceResId public
Turns out this method is generaly useful outside of View construction.

Test: added CTS test
Bug: 127855851
Change-Id: Ia2a5a3a9dc5eac5a1da51e7df6989bb09b141141
2019-03-08 22:09:08 +00:00
Aurimas Liutikas
908309feb5 Merge "Clean up attribute apis based on api council feedback." 2019-03-08 22:02:17 +00:00
Philip P. Moltmann
8af0210f0e Merge "Get permissions flags with GET_RUNTIME_PERMISSION" 2019-03-08 21:34:01 +00:00
TreeHugger Robot
d1bd765392 Merge "Add RoleControllerManager for role controller service." 2019-03-08 21:32:00 +00:00
Jon Miranda
9350598635 Address API review for SessionInfo, LauncherApps
Bug: 126699560
Test: Built and flashed manually
Change-Id: I0026eaa7dfd5afb06cfa9c6fc43a25585fa9f20f
2019-03-08 09:33:42 -08:00
Philip P. Moltmann
fc202f748f Get permissions flags with GET_RUNTIME_PERMISSION
Only require a less-powerful, but heavily restricted permission to the
the permission flags.

Bug: 124317989
Test: Built
Change-Id: Ibdd6baea6dcee57dc327c28663a136e47e80dcb8
2019-03-08 08:52:10 -08:00
TreeHugger Robot
30579cd805 Merge "Introduce ApplicationInfo.getAllApkPaths()." 2019-03-08 16:32:07 +00:00
shafik
fee3acf15d API cleanup: add NonNull annotation to Rollback API
Annotate the return values of RollbackInfo, PackageRollbackInfo and
RollbackManager API methods as NonNull.

Fixes: 126863286
Fixes: 126698364
Fixes: 126699071
Fixes: 126700362
Fixes: 126701437
Test: build
Change-Id: Id10a9edbf21a239f310ba1ee25ec96cf665c3d3e
2019-03-08 15:44:26 +00:00
Philip P. Moltmann
c87cf2cb9e Merge changes from topic "userSensitive"
* changes:
  Small issues with FLAG_PERMISSION_USER_SENSITIVE_*
  Introduce and populate PackageManager.FLAG_PERMISSION_USER_VISIBLE
2019-03-08 15:24:56 +00:00
TreeHugger Robot
a7010101dc Merge "Rename downgrade-related install flags" 2019-03-08 11:53:21 +00:00
Hai Zhang
a4959e569d Add RoleControllerManager for role controller service.
This allows us to expose both system-only and app available APIs for
role in RoleControllerService.

Bug: 127691087
Test: manual
Change-Id: I86fe3736fc28516aae25d48efe3ba599ffdf45d5
2019-03-07 21:33:12 -08:00
TreeHugger Robot
e0894ab25d Merge "Add Context.bindService with executor parameter" 2019-03-08 02:08:51 +00:00
Philip P. Moltmann
7659769d3c Small issues with FLAG_PERMISSION_USER_SENSITIVE_*
Add them to the "all flags" mask. We cannot change the value of a
constant in the API, hence need to deprecate it. This change does
not create a new API with the new value to not have the same problem
again.

Register the flag type in the IntDef and toString methods.

Test: Set permission flags, rebooted and verified that flags get
      restored.
Bug: 124317989
Change-Id: Ia68053a937be7dc47af6e313e66e87f3228a2d14
2019-03-07 16:23:11 -08:00
Eugene Susla
21fc69e827 Introduce and populate PackageManager.FLAG_PERMISSION_USER_VISIBLE
Bug: 124317989
Test: adb shell dumpsys package com.google.android.apps.messaging
and ensure permissions without flag GRANTED_BY_DEFAULT have flag USER_VISIBLE
Change-Id: Ie3129a87a4391cb5a52ccda1b84fa46585850432
2019-03-07 16:23:11 -08:00
Aurimas Liutikas
f9dbd5fed6 Clean up attribute apis based on api council feedback.
Bug: 127714248
Test: None
Change-Id: I40596a88e7e446c6a25f2b9074bb88a0a417ed63
2019-03-07 14:23:59 -08:00
Torne (Richard Coles)
1aaae10e77 Introduce ApplicationInfo.getAllApkPaths().
Add an internal method to ApplicationInfo to get all APK files that may
be required by an application. This moves assumptions about how apps are
constructed out of Zygote.allowAppFilesAcrossFork and into a more
appropriate place where it can be shared.

Bug: 124116212
Test: atest android.webkit.cts.WebViewTest
Change-Id: I79add98c4922c4f97263bff78cf808bc38274755
2019-03-07 13:59:45 -05:00
TreeHugger Robot
6f42bb2e8b Merge "Mark getStagedSessionErrorMessage as @NonNull." 2019-03-07 17:42:50 +00:00
Dario Freni
aa796c19d1 Mark getStagedSessionErrorMessage as @NonNull.
Change-Id: I269175f24ef84e7e8b053528ab1074dad84bb6fe
Fix: 126698886
Test: n/a
2019-03-07 15:09:20 +00:00
Philip P. Moltmann
a3e79d624c Merge "Add annotations and finals to PermissionInfo" 2019-03-06 23:43:05 +00:00
TreeHugger Robot
3c37379061 Merge "Added LocusId support to Shortcut and Notification." 2019-03-06 21:49:46 +00:00
Philip P. Moltmann
a4844d1fb9 Add annotations and finals to PermissionInfo
... and deprecate constructors that should not be called anymore.

Test: Looked at permissions (incl 3rd party) in UI
Fixes: 126701534
Change-Id: Ic5ceb522ca75d130001add47a1a3dcb2ea8f7e8f
2019-03-06 13:00:25 -08:00
Bo Liu
58a57667e4 Add Context.bindService with executor parameter
Allow app to control the thread where ServiceConnection methods are
called on.

Bug: 111434506
Test: Used new bindContext method in chrome and checked callbacks
are on the correct thread.

Change-Id: I480e5bd6773a530fb9e8e73e3a2a2a88b76569ec
2019-03-06 20:21:45 +00:00
Nikita Ioffe
b1d60f1b01 Rename downgrade-related install flags
Renaming according to the comment in ag/6614840

Test: RollbackTest on user build
Bug: 127322579
Fixes: 127322579
Change-Id: I14abc9cf8fa41bd8ca7802a6b241f59c8f468400
2019-03-06 19:14:41 +00:00
Adam He
682ea3ccfd Merge changes from topic "aa_whitelist"
* changes:
  Check for empty arguments in setWhitelist().
  Implemented a WhitelistHelper for whitelisting packages/activities for Augmented Autofill and Content Capture.
2019-03-06 18:31:59 +00:00
Jeff Sharkey
715b34be65 Merge "Add trivial nullability annotations." 2019-03-06 16:17:56 +00:00
Jeff Sharkey
ba4acd5575 Add trivial nullability annotations.
Bug: 126702077, 126701263, 126700858, 126700497
Test: manual
Change-Id: Ic6599f59e6e079097a35cb2bf24c59a87627c8b7
Exempt-From-Owner-Approval: Trivial API annotations
2019-03-05 19:48:55 -07:00
Adam He
70ebc5a508 Check for empty arguments in setWhitelist().
Bug: 125348180
Test: atest CtsContentCaptureServiceTestCases
Test: atest FrameworksCoreTests:com.android.internal.infra.WhitelistHelperTest
Change-Id: I9c2296ebe2762e97f03350b365b148429b15ab60
2019-03-05 14:51:30 -08:00
Felipe Leme
90205ef423 Added LocusId support to Shortcut and Notification.
Test: atest FrameworksCoreTests:android.app.NotificationTest#testBuilder_setLocusId
Test: atest CtsShortcutManagerTestCases:android.content.pm.cts.shortcutmanager.ShortcutManagerClientApiTest
Test: atest CtsShortcutManagerTestCases # sanity check; some tests are failing, but pass individually

Test: m update-api
Bug: 126945732

Change-Id: Ib819a63aa008ab952b02da8c0be1b528814dfb00
2019-03-05 13:38:57 -08:00
TreeHugger Robot
4876191cad Merge "Checks for null id on LocusId constructor." 2019-03-05 21:05:38 +00:00
Philip P. Moltmann
06f309c1c0 Merge "Add annotations and finals to PermissionGroupInfo" 2019-03-05 19:26:54 +00:00
TreeHugger Robot
48636daaf8 Merge "Add new permission to guard Intent.REVIEW_ACCESSIBILITY_SERVICES." 2019-03-05 17:51:36 +00:00