15050 Commits

Author SHA1 Message Date
Lorenzo Colitti
bfecba2938 Speed up ConnectivityServiceTest.
1. Override WakeupMessage with an implementation that uses
   sendEmptyMessageDelayed. This allows us to replace a
   6-second sleep with a 150ms wait.
2. Change waitFor()'s polling interval from 100ms to 50ms.

With these changes ConnectivityServiceTest goes from ~9s to ~3s.

Change-Id: Id78aab9cded90a5b17f09d7f437904e179808dd2
2016-03-02 17:01:50 +09:00
Wale Ogunwale
5b30f0df3f Merge "Enable add/remove window manager log points" into nyc-dev 2016-03-02 04:46:53 +00:00
Wale Ogunwale
3102c87a74 Enable add/remove window manager log points
To debug 27286867.

Bug: 27286867
Change-Id: Iab5e608f8437ee0e315bfa3d091980f4a9e3a3b5
2016-03-01 20:42:53 -08:00
Jeff Sharkey
f7d47f91fe Start unaware persistent apps after user unlocked.
Otherwise we'll never start them.  In particular, this fixes NFC.

Bug: 27360562
Change-Id: I9d430b1e377e63b35060b234f585ac180a369ad2
2016-03-01 18:38:55 -07:00
Jeff Sharkey
8b609f3a96 Merge "Make preferred activities encryption aware." into nyc-dev 2016-03-02 00:52:35 +00:00
Jeff Sharkey
8e28443aa7 Merge "Utility to detect lock inversions in system." into nyc-dev 2016-03-02 00:52:21 +00:00
Svetoslav Ganov
2ab93cb22a Merge "Hide overlay windows in VR mode" into nyc-dev 2016-03-01 23:02:31 +00:00
Svetoslav Ganov
47d98de60b Hide overlay windows in VR mode
bug:26775563

Change-Id: I0e81cc64f281cd085ff642ebd93f32ceb3ad5480
2016-03-01 15:01:20 -08:00
Felipe Leme
2657492e5a Merge "Created netpolicy commands to manage UIDs blacklisted for network access while on background." into nyc-dev 2016-03-01 22:43:13 +00:00
Jeff Sharkey
258be56dcd Make preferred activities encryption aware.
Not all built-in apps are encryption aware, so match them all when
setting up preferred activities.

Bug: 27429841
Change-Id: I0fd2195714fac95d031813bab73125a5c7b6c81a
2016-03-01 15:15:58 -07:00
Dongwon Kang
9cd89a403e Merge "TIF: Address API review comments" into nyc-dev 2016-03-01 22:11:47 +00:00
Felipe Leme
9982b3076b Created netpolicy commands to manage UIDs blacklisted for network access
while on background.

These commands will be used primarily in the CTS tests:

- list restrict-background-blacklist
- add restrict-background-blacklist UID
- remove restrict-background-blacklist UID

BUG:  27432317
Change-Id: Ie1148dcabbb2481ccd39659a813fac3776f84e3b
2016-03-01 13:40:31 -08:00
Dianne Hackborn
a6dcaa6f84 Merge "Fix issue #27317952: PendingIntent.getIntent() should be protected" into nyc-dev 2016-03-01 20:57:02 +00:00
Todd Kennedy
4f858aaa5a Merge "Revert "Revert "Remove deprecated methods / classes""" into nyc-dev 2016-03-01 20:39:59 +00:00
Wale Ogunwale
4722231184 Merge "Changed logging format of lost windows to reduce confusion." into nyc-dev 2016-03-01 20:34:50 +00:00
Wale Ogunwale
6e66695777 Merge "Add activity onStop lifecycle to event logs." into nyc-dev 2016-03-01 20:34:15 +00:00
Robin Lee
2f4286b792 Merge "ConnectivityService: listen to USER_UNLOCKED too" into nyc-dev 2016-03-01 20:09:45 +00:00
Julia Reynolds
9e65739c19 Merge "Protect against a lack of metadata." into nyc-dev 2016-03-01 18:56:16 +00:00
Clara Bayarri
78f335e753 Merge "Fix Fingerprint confusing personal and work fingerprints when unified" into nyc-dev 2016-03-01 18:07:05 +00:00
Dongwon Kang
b55c7517ba TIF: Address API review comments
Bug: 27386052
Change-Id: I242819e0817723e247b8fe646d534899ab50af76
2016-03-01 10:03:58 -08:00
Calin Juravle
e1ac71fe99 Merge "Restrict the cases when we profile guided compile an apk" into nyc-dev 2016-03-01 17:59:20 +00:00
Chong Zhang
168d5e4e2e Merge "Check task.isResizeable() instead of the resize mode directly" into nyc-dev 2016-03-01 17:58:17 +00:00
Fyodor Kupolov
c453905afc Merge "Fixed handling of blockUninstall setting" into nyc-dev 2016-03-01 17:39:13 +00:00
Julia Reynolds
7f2f441783 Protect against a lack of metadata.
Change-Id: Idc28ac451567e8ee4772d9db3009102d781e6331
2016-03-01 12:33:48 -05:00
Amith Yamasani
5fea67e88e Merge "Heed user shell restriction for pm calls" into nyc-dev 2016-03-01 17:10:27 +00:00
Wale Ogunwale
cd7043e99a Add activity onStop lifecycle to event logs.
Also added reasons why onPause and onResume are called.

Bug: 27384433
Change-Id: If6c304f577b601511f6d9b948061d2cfa0dcb970
2016-03-01 07:29:17 -08:00
Todd Kennedy
a67932374d Revert "Revert "Remove deprecated methods / classes""
This reverts commit 5cbeb5902633646fbc0a1be252081e77aaaee7b4.

Change-Id: Id96010364d65e6131221ebbcc8ce5889a2da256c
2016-03-01 07:19:33 -08:00
Julia Reynolds
2319dd3a66 Merge "Api review: AutomaticZenRule" into nyc-dev 2016-03-01 15:05:36 +00:00
Chong Zhang
d545dce4b9 Check task.isResizeable() instead of the resize mode directly
The resize mode doesn't take into account developer settings override.

Bug: 27390258
Change-Id: Id161ceb4f143f982f6bec3f915655bb66949ddd3
2016-02-29 18:11:42 -08:00
Dianne Hackborn
e5ad41bc02 Fix issue #27317952: PendingIntent.getIntent() should be protected
Change-Id: Ib05135cd94f5251942a6fc6df542ed39083f7827
2016-02-29 18:02:43 -08:00
Clara Bayarri
35fd938105 Fix Fingerprint confusing personal and work fingerprints when unified
When the personal and work profile have unified locks, FingerprintService
was retrieving the credential owner and returning the personal data
even when explicitely asked for the work profile.
Bug: 27408217

Change-Id: I67d20f92e0016e4ccd38f8b19edebc543830df4a
2016-02-29 17:49:18 -08:00
Fyodor Kupolov
c4967e7161 Fixed handling of blockUninstall setting
Previously, if one user has blockUninstall, it will block uninstalling
the package for all users. Now the package is uninstalled for all users,
excluding the ones that have blockUninstall setting.

Bug: 24616123
Change-Id: Ie4a68ef97fbef4711b18ccd311e39f32ab4b8efe
2016-02-29 17:47:02 -08:00
Svetoslav Ganov
a0021cbb7f Merge "Proper grant default permissions to default SMS and Phone" into nyc-dev 2016-03-01 01:40:37 +00:00
Amith Yamasani
5ebdefd0db Heed user shell restriction for pm calls
Make sure that a restricted user cannot use adb shell commands
to grant/revoke runtime permissions.

Bug: 27418014
Change-Id: I518b09f56ca7d77cc2bfa1d0b4faaf129e19000d
2016-02-29 17:35:01 -08:00
Svetoslav Ganov
80d78dc92b Proper grant default permissions to default SMS and Phone
We grant default permissions to the default SMS and
Phone apps when they are selected as such to ensure
they can do their job. We don't grant default permissions
to apps if the version on the system image does not
declare them. This is correct for default grants on
first boot or a new user creation. This is a problem
for default Phone and SMS as we want to grant them
the permission as a result of a deliberate user action
and therefore should not care if the version on the
system image declares the permission.

As a result if an SMS app that ships as a stub to reduce
image size is later updated to the full version and
made the default SMS it would not get the default grants
while an installed third-party app that did not ship
on the system image would get the grants.

This change ensures the default SMS and Phone get
their default grants regardless whether the verion on
the system image declares the permissions.

bug:25288760

Change-Id: I2fecf5cbce4ebabb145a3f29abb555bcb65d54d6
2016-02-29 17:29:43 -08:00
Clara Bayarri
30f0ff2a1c Merge "Unlock Keystore/Keymaster separately for Work Challenge" into nyc-dev 2016-03-01 01:08:39 +00:00
Dianne Hackborn
72041bb2c6 Merge "Fix issue #27385109: control activity behavior without triggering..." into nyc-dev 2016-03-01 00:35:40 +00:00
Chris Tate
d1bb54b80e Merge "Reintroduce per-app scheduled job limits" into nyc-dev 2016-03-01 00:27:29 +00:00
Phil Burk
4e572d32f8 Merge "AudioService: add support for ENCODED_SURROUND_OUTPUT" into nyc-dev 2016-03-01 00:06:21 +00:00
Jeff Sharkey
8cac67b616 Merge "Need to clear identity when rebooting for FBE." into nyc-dev 2016-03-01 00:03:29 +00:00
Jeff Sharkey
1176e51b49 Need to clear identity when rebooting for FBE.
Bug: 27412530
Change-Id: I6d5b925a16daefd1b6906ce036faeb6244d503fb
2016-02-29 17:01:30 -07:00
Wale Ogunwale
6aeeb21b6b Merge "Use realActivity name when comparing if intents are the same" into nyc-dev 2016-02-29 22:38:29 +00:00
Wale Ogunwale
715a1dcffd Use realActivity name when comparing if intents are the same
The TaskRecord intent (usually the intent of the root activity) component
names are based on the realActivity (the activity we are actually launching
and not the input alias) and the ActivityRecord intent is based on the input
component name which can be an alias. This leads to issues when we are trying
to compare the intent of a task and an activity to see if they resolve to
the same thing since the component names will be different in the case of
aliasing.
We know base the activity intent component name on the realActivity before
comparing with the task record intent.

Bug: 27403679
Bug: 27112965
Change-Id: I196e03bb018582cbac977fb3ad45354f00f51578
2016-02-29 14:27:32 -08:00
Colin Cross
414c529a4f Merge "Add dumpsys meminfo --unreachable" into nyc-dev 2016-02-29 22:19:40 +00:00
Svet Ganov
6ac25c5641 Fix uninstalling apps with damaged/gone APK files
bug:27394497

Change-Id: I0d0317f2d7168be4412a24d34a9f23f04c6d8601
2016-02-29 12:44:44 -08:00
Dianne Hackborn
4a18c26609 Fix issue #27385109: control activity behavior without triggering...
...isUserAMonkey for testing purpose

Add an argument for the caller to specify if they are a poo flinging
monkey.

Change-Id: I0e149a8d78776abaf07517bd4ae886047b7f4252
2016-02-29 12:37:11 -08:00
Phil Burk
ac0f704b1a AudioService: add support for ENCODED_SURROUND_OUTPUT
Preference allows override of AudioPolicyManager.
Lets user force or prevent use of AC3 and DTS regardless
of what the EDID says.

Bug: 26373761
Change-Id: I21440f2b90af9a369a36b7b07724e992501bce6d
Signed-off-by: Phil Burk <philburk@google.com>
2016-02-29 12:20:43 -08:00
Jeff Sharkey
ca6abfd9d6 Delay migration until after user is prepared.
We don't have a vold connection early in the PackageManagerService
constructor, so we can only migrate the system user at boot.  We now
migrate other users only after they're explicitly unlocked by
UserManagerService.

Bug: 27330415
Change-Id: I29f21714acf65a598b8df496af0f7d2cb1d247c4
2016-02-29 12:07:14 -07:00
Clara Bayarri
0a587d2840 Unlock Keystore/Keymaster separately for Work Challenge
The Keystore should be unlocked by the work challenge when
the work profile has its own lock, and should not be unlocked
by the device lock in this case.

Tested use cases:

When unified, both users have the password key set to the parent's
Setting a work challenge changes the work profile's password key to its
own
Unifying causes the work challenge key to be set to null first and then
when the device password is reset right after that it is reset to the
same as the parent
Unlocking when locks are unified unlocks both using the same password
key
Unlocking the device when not unified only unlocks the parent
Unlocking the work challenge only unlocks the work profile

Bug:26817206
Change-Id: I99dca279687f4f77636992e355dbdb607bbf7b6d
2016-02-29 10:06:54 -08:00
Robin Lee
89e7a696f0 ConnectivityService: listen to USER_UNLOCKED too
When the credential-encrypted private storage for the target user is
unlocked, we should try to start up VPN for them.

Bug: 27357283
Change-Id: Id9079230d00e3cea08a49ae66bd1f553416b4f54
2016-02-29 16:29:44 +00:00