Commit Graph

12811 Commits

Author SHA1 Message Date
TreeHugger Robot
df0d0f1a84 Merge "Extend XML parser to allow optional requiredFlags attribute for <include /> rules in <full-backup-content> specification" 2018-02-20 19:20:00 +00:00
TreeHugger Robot
414189fefe Merge "APIs to watch active op changes" 2018-02-20 18:46:57 +00:00
Kodlee Yin
3feba764d6 Merge "Add Notification.Action.SEMANTIC_ACTION_CALL" 2018-02-20 18:39:19 +00:00
Michal Karpinski
34b769d32b Extend XML parser to allow optional requiredFlags attribute
for <include /> rules in <full-backup-content> specification

Give an app developer the option to include files based on the
transport flags exposed by the transport. This allows conditionally
including files as long as the transport identifies itself as
for instance encrypted or device-to-device.

Extend the parsing mechanism to read optional requiredFlags
attributes, and extend existing structures to encompass
that data for BackupAgent to retrieve and act on it
based on FullBackupDataOutput#getTransportFlags().

Bug: 72484288
Test: runtest frameworks-core -c android.app.backup.FullBackupTest
Test: make cts -j40 && cts-tradefed run cts -m CtsBackupHostTestCases -t android.cts.backup.FullbackupRulesHostSideTest
Change-Id: Ibf12995796963f87ed19d9e357ae8546037e5f53
2018-02-20 13:46:16 +00:00
Bernardo Rufino
b331d1f1ef Merge "Add local transport parameters for transport flags GTS test" 2018-02-18 18:00:22 +00:00
TreeHugger Robot
0c200baed4 Merge "Minor autofill changes to support compat mode CTS tests." 2018-02-17 11:17:05 +00:00
Svetoslav Ganov
2d20fb47f4 APIs to watch active op changes
System singed components can watch for starting/finishing of
long running app ops. Also protected the APIs to watch op mode
changes with a singature permission for the cross-uid use case.

Test: atest com.android.server.appops.AppOpsActiveWatcherTest

bug:64085448

Change-Id: Id7fe79ce1de4c5690b4f52786424ec5a5d9eb0fa
2018-02-16 18:29:04 -08:00
Svet Ganov
47b37aa034 Minor autofill changes to support compat mode CTS tests.
Bug: 72811561
Test: atest CtsAutoFillServiceTestCases:VirtualContainerActivityCompatModeTest

Change-Id: I6ec2563cea75afc77a1598805988d8e6c433c574
2018-02-16 18:01:17 -08:00
Jeff Sharkey
5e4bebb891 Merge "Better handling of NTP-based clocks." 2018-02-16 22:13:01 +00:00
Jeff Sharkey
9911a28adb Better handling of NTP-based clocks.
Now that we have a nice Clock abstraction, we can use it to represent
a clock backed by an NTP fix.  (This makes testing logic much easier
to write.)

We now rely completely on NetworkTimeUpdateService to keep our NTP
fix up to date, instead of trying to refresh in the middle of
critical paths which could trigger random ANRs.

Add internal FallbackClock to make it easier to handle missing NTP
fixes.  Add internal SimpleClock to let implementers focus on single
millis() method.

Test: bit FrameworksNetTests:com.android.server.net.NetworkStatsServiceTest
Test: bit FrameworksServicesTests:com.android.server.NetworkPolicyManagerServiceTest
Bug: 69714690, 72320957
Change-Id: Ic32cdcbe093d08b73b0e4b23d6910b23ea8e1968
Exempt-From-Owner-Approval: approved in previous PS
2018-02-16 22:11:35 +00:00
Rajeev Kumar
334899b0d8 Merge "Implement atom puller for ProcessMemoryState." 2018-02-16 21:52:22 +00:00
Jeff Sharkey
2ab510ee24 Merge "Add RequiresFeature annotation." 2018-02-16 20:45:41 +00:00
Jeff Sharkey
98af2e4fec Add RequiresFeature annotation.
Certain APIs require that a device have a specific feature to operate
correctly, so start annotating them.

Test: builds, boots
Bug: 72284763
Change-Id: Ie2f30284bdfdb6acc4067f434eba3b5433837606
Exempt-From-Owner-Approval: simple annotations
2018-02-16 20:45:22 +00:00
Kodlee Yin
cda5b09e32 Add Notification.Action.SEMANTIC_ACTION_CALL
Adds the Call semantic action which allows apps to declare an action as
one that will perform a call. No logical changes.

Test: none
Bug: 67717177
Change-Id: I2bc63122ca285ba504f004da05ea79db74c01e08
2018-02-16 11:02:18 -08:00
Bernardo Rufino
eaa78b92a5 Add local transport parameters for transport flags GTS test
Added parameters for local transport in secure setting for setting up
local transport to test transport flags GTS test.

Test: GTS test in topic CL.
Bug: 73100304
Change-Id: If654175d91fdf1ea68db0f3320d59b2b770a4db3
2018-02-16 16:25:47 +00:00
Peter Visontay
1cfc06a1e5 Merge "Remove the OP_REQUEST_DELETE_PACKAGES op from the list of runtime permissions." 2018-02-16 09:54:09 +00:00
Felipe Leme
5b32ebe4df Improved Autofill logging.
Test: manual verification
Bug: 73172668

Change-Id: I8c77f2a792f3195efa44f44a4c9888c355eaee3c
2018-02-15 15:04:51 -08:00
Rajeev Kumar
22d92b76bc Implement atom puller for ProcessMemoryState.
We would like to gather memory metrics of the processes when LMKD kills
a process. By gathering this info we would be able to analyze and improve
system health by potentially reducing memory footprint of the processes
contributing to the memory pressure on the device.

This feature would be available on production builds.

Perf analysis:
On an average getMemoryStateForProcesses method call takes
0.59 milli seconds per process.

To know more about this see: http://go/android-p-memory-metrics

Bug: 72177881
Test: Tested manually
Change-Id: Ice94c2d937a5c84bc205981d99588a30f686ff9b
2018-02-15 13:43:55 -08:00
Peter Visontay
827f231aea Remove the OP_REQUEST_DELETE_PACKAGES op from the list of runtime permissions.
It was added to that list by mistake.

Bug: 63907873
Test: CtsPermissionTestCases:AppOpsTest
Test: built the platform
Change-Id: I30448bfe5a0816303c9900bd120b1db57f78bc54
2018-02-15 17:48:16 +00:00
TreeHugger Robot
4db3ca08dc Merge "Add Backup and Restore directory OWNERS" 2018-02-15 17:14:16 +00:00
Michal Karpinski
c31222f009 Add Backup and Restore directory OWNERS
Bug: 73454476
Change-Id: Id28cbf7d919e95720c51d6a14388e9fea9d84650
2018-02-15 14:50:44 +00:00
David Brazdil
66f75f9ce1 Merge "Update hidden API toast message" am: 10034d94cf am: 42ab3eeb4c
am: 0a6ca96902

Change-Id: I2cc692827716043e0f9065c9c1be932642ed5856
2018-02-15 14:40:43 +00:00
David Brazdil
0a6ca96902 Merge "Update hidden API toast message" am: 10034d94cf
am: 42ab3eeb4c

Change-Id: I6c82dc811f3118733d3afffa7ddb6d5016d4f075
2018-02-15 13:14:49 +00:00
David Brazdil
42ab3eeb4c Merge "Update hidden API toast message"
am: 10034d94cf

Change-Id: I7e5c4c5333be8d1bc5722b0924c31a8ad94be29e
2018-02-15 13:01:54 +00:00
David Brazdil
10034d94cf Merge "Update hidden API toast message" 2018-02-15 11:55:15 +00:00
David Brazdil
5234d559b4 Update hidden API toast message
Change the toast message shown by an Activity when VMRuntime reports
that the app has used a private API.
(a) fix a typo: compatiblity -> compatibility
(b) change guidance from "please consult log" to "go to <url> for
    more info" where devs can learn how to proceed if their app does
    have compatibility issues.

Bug: 64382372
Test: make, visual
Change-Id: Idbe32a724438bb7b0826d0b4e11ef505015cb321
2018-02-15 09:09:55 +00:00
TreeHugger Robot
ce3f5d00f9 Merge "Added new AM method: updatePersistableUriPermission()" 2018-02-15 06:59:31 +00:00
TreeHugger Robot
67d9a90b63 Merge "Fix javadoc to match event payload content." 2018-02-15 06:17:39 +00:00
TreeHugger Robot
f781a621cb Merge "Clear lifecycle description on recycle and improve logging." 2018-02-15 05:31:17 +00:00
Jorim Jaggi
d067decc07 Merge "Override all transitions from package start" 2018-02-15 01:34:37 +00:00
Felipe Leme
7a429721de Added new AM method: updatePersistableUriPermission()
This method will be used by the DocumentUI's ScopedDirectoryProvider
to update (grant or revoke) Scoped Directory Access permissions.

NOTE: it's currently implemented both on AM and AMS, but the latter will be
replaced by calls to takePersistableUriPermission() or
releasePersistableUriPermission().

Test: manual verification
Test: atest CtsAppSecurityHostTestCases:ScopedDirectoryAccessTest#testResetDoNotAskAgain,testResetGranted
Test: atest CtsAppSecurityHostTestCases:ScopedDirectoryAccessTest

Bug: 63720392
Bug: 72055774

Change-Id: Icd7c8b7756d78fd137ba7b05ab5e35efdfcd19af
2018-02-14 16:26:22 -08:00
Bryce Lee
f52974c812 Clear lifecycle description on recycle and improve logging.
This changelist clear any custom description set on a lifecycle item
and improves the data logged. This changelist should be reverted once
the root cause has been discovered.

Bug: 71506345
Test: manual
Change-Id: I38edb292684745e6e912b3ba09fb220bf7f39149
2018-02-14 15:55:08 -08:00
Pavel Grafov
c6fe1e0430 Fix javadoc to match event payload content.
Test: only comments has changed.
Bug: 70886042

Change-Id: I3b46ea689794c61e1ac6916db95feff364a25c1b
2018-02-14 22:05:40 +00:00
Jorim Jaggi
04dc5968c0 Override all transitions from package start
When launching a notification, often the launch goes into a
service, broadcast or trampoline activity that starts another
activity, for which we loose the ability to control the animation
because we don't provide the activity options anymore.

This CL adds the ability to override all activity launches
originating from a certain package for a couple of seconds, such
that we have the ability to still control the animation from
SystemUI.

Test: go/wm-smoke
Test: Start stopwatch, press home, press notification
Test: atest PendingRemoteAnimationRegistryTest
Change-Id: I4d077c4ac4565f060e849e4b33920d2bf4a80d48
2018-02-14 13:52:45 -08:00
TreeHugger Robot
4963ce8efc Merge "Add support for url_bar sanitization on autofill compat mode." 2018-02-14 20:22:31 +00:00
Felipe Leme
185de72695 Add support for url_bar sanitization on autofill compat mode.
Browsers typically use a standard class (like EditView) to hold the URL of the
page being loaded, and the content of that view is sanitized in the initial
autofill request. So, when running in compat mode, we need a mechanism to let
services tell which view contains the URL, so we can convert its contents to
a sanitized webScheme + webDomain pair or properties.

Test: manual verification
Fixes: 72994424

Change-Id: I8be5f3533d6c31f81f28036dc51d5de10a528079
2018-02-14 09:43:21 -08:00
Wale Ogunwale
4357d119af Remove Activity#setDisablePreviewScreenshots from system API
Change-Id: Ie106fb77f4645cc0c9061f4b6f7a4546711e5cb3
Bug: 73250551
Test: N/A
2018-02-14 07:21:52 -08:00
Wale Ogunwale
427ef56c0f Merge "Deprecated onCreateThumbnail" 2018-02-14 14:28:18 +00:00
TreeHugger Robot
18869a30b6 Merge "NIAP: Log cert validation and key integrity failures." 2018-02-14 13:45:40 +00:00
Rubin Xu
7b7b3b2090 Merge "Add System API for system update clients" 2018-02-14 02:14:59 +00:00
Holly Jiuyu Sun
02d43443d0 Merge "Public EuiccManager APIs." am: 42339c464f
am: cddc0c12cc

Change-Id: I01d436c16df678292c8aec1f3ea2d7a65f3e10dd
2018-02-14 00:24:46 +00:00
Holly Jiuyu Sun
cddc0c12cc Merge "Public EuiccManager APIs."
am: 42339c464f

Change-Id: I95f1713b1a1be188e7eae62adbfc975bfca982c3
2018-02-14 00:08:35 +00:00
Holly Jiuyu Sun
052fbabc35 Public EuiccManager APIs.
Public EuiccManager and other related necessary files.
Mark EuiccCardManager and other related necessary files as @SystemApi.
Solve lint errors and warnings.

Bug: 35851809
Test: test on phone
Change-Id: I8a2c78804cae56b679d311d613edca5be4bc2522
Merged-In: I68853e134e1e31fa9b91a83af6c491a2a8cca971
2018-02-13 12:53:45 -08:00
Pavel Grafov
f8839eaaf7 NIAP: Log cert validation and key integrity failures.
Bug: 70886042
Test: manual, connect to EAP-TLS with self-signed cert.
Test: manual, create a key and damage it in /data/misc/keystore/user_0/
Change-Id: I61a8307da72bac38993f6588e9f184b360f6bf79
2018-02-13 19:22:04 +00:00
Wale Ogunwale
578b3bd59d Deprecated onCreateThumbnail
API hasn't done anything in the platform for ages and there is not plan
to make it do anything.

Change-Id: I7d433a0d45aed860659c311381bc9f356eb9f986
Fixes: 73249948
Test: builds
2018-02-13 10:59:18 -08:00
Rhiannon Malia
619e2c0d61 Merge "Adding suppressShowOverApps to TvExtender" 2018-02-13 18:14:31 +00:00
TreeHugger Robot
d71e03f0a1 Merge "Fix work profile shortcut launch" 2018-02-13 09:07:36 +00:00
TreeHugger Robot
f91f5dc809 Merge "API Review: Nullability annotation for DeviceAdminReceiver device owner user callback" 2018-02-13 04:18:32 +00:00
Rubin Xu
658d7bbf1d Add System API for system update clients
Introduces the concept of installation option and new system API for system
update clients to convert a complex SystemUpdatePolicy into a simple action
and an effective time, under any given time. This should abstract away the
current complexity in SystemUpdatePolicy and all system update clients only
need to query the current installation option and act on it, without the need
to understand or implement other logic related to the policy.

Test: gts-tradefed run gts-dev --module GtsGmscoreHostTestCases --test com.google.android.gts.devicepolicy.DeviceOwnerTest#testSystemUpdatePolicy --ignore-business-logic-failure
Test: runtest frameworks-services -c com.android.server.devicepolicy.SystemUpdatePolicyTest
Bug: 72939648
Bug: 64813061
Change-Id: I92537c7b99103a807d8adcbe2dc01b42a9740068
2018-02-13 02:40:11 +00:00
Makoto Onuki
7041c4b96b Fix work profile shortcut launch
Shortcuts let the launcher start activities on work profile, so we can't apply
the usual cross-user startActivity check.

LauncherApps already checks the calling user and the target user relationship,
so let's just skip the handleIncomingUser check.

Bug: 72659387
Test: atest CtsShortcutManagerTestCases
Test: atest ${ANDROID_BUILD_TOP}/cts/hostsidetests/shortcuts/hostside/src/android/content/pm/cts/shortcuthost/ShortcutManagerMultiuserTest.java

Change-Id: I3b6179af0c9d5e54ed8fd57c9c830f7a6ecec9da
2018-02-12 15:48:02 -08:00