Commit Graph

2893 Commits

Author SHA1 Message Date
Ricardo Cervera
97c4ba9862 docs: Added info on noHistory and onActivityResult().
Bug: 13807256

Cherry-pick from Iae4901a311e76401396f89c552e5b27a49c65c83

Change-Id: I4ad7aea1a3c7ea82bc2bbcdf35d2de418ef7b90f
2015-01-16 09:24:30 -08:00
Jeff Sharkey
d68b87cdd4 Recover apps with malformed certificates.
There was a window of time in Lollipop where we persisted certificates
after they had passed through a decode/encode cycle.  The well-written
OpenSSL library was liberal when decoding (allowing slightly malformed
certs to be parsed), but then strict when encoding, giving us
different bytes for effectively the same certificate.

A related libcore change (0c990ab4a90b8a5492a67b2b728ac9a4a1ccfa1b)
now returns the original bytes verbatim, fixing both pre-Lollipop
installs and installs after that change.

This change recovers any apps that had been installed during the
window of time described above by doing a one-time check to see if
the certs are effectively equal.

Bug: 18228011
Change-Id: Ib82bd6db718d0490d7a26c9c1014b7c8457a7f2d
2014-11-12 13:16:06 -08:00
Jeff Sharkey
97d47ed036 Reduce PackageInstaller Binder memory pressure.
When restoring hundreds of apps on low-DPI devices, we end up sending
icon Bitmaps inline in the response instead of splitting into ashmem
regions.  To avoid triggering TransactionTooLargeException, switch to
using ParceledListSlice under the hood.

Bug: 17926122
Change-Id: Ib4da6775e79d2fcb4aaea15f58ed998df203a5f9
2014-10-15 09:19:54 -07:00
Jeff Hao
dbfbb17512 Backport of ordering apps for boot dexopt.
This is a squashed commit of the following changes:

1. Order apps by priority when performing boot dexopt.
   (cherry picked from commit 65cde7d42d)

2. Improve priority ordering of apps when performing boot dexopt.
   Added core apps and updated system apps.
   (cherry picked from commit 272bf3a274)

3. Stop boot dexopt when low on memory.
   (cherry picked from commit 1d892dcb6b)

Bug: 17641843
Change-Id: Ie32f1c21047d3462aaf728f7633fecf647ba2b47
2014-10-14 15:02:37 -07:00
Dianne Hackborn
89b196958f Merge "Put in real "code" (aka marketing) name." into lmp-dev 2014-10-08 17:59:19 +00:00
Jeff Sharkey
7f1a57a3e7 Bring along more ApplicationInfo fields.
When we added scan paths, we forgot to bring them along through
Parcel and copy constructor.

Bug: 17900178
Change-Id: I0ee9374f909d375768045976fd88cee7431f7d4d
2014-10-08 10:14:53 -07:00
Dianne Hackborn
955d8d69ea Put in real "code" (aka marketing) name.
Change-Id: Idb3976edfae37293ed75cb5b869b4b42d8042bbe
2014-10-07 20:17:19 -07:00
Jeff Sharkey
99586dc010 Merge "Reduce PackageInstaller I/O pressure." into lmp-dev 2014-10-06 23:51:56 +00:00
Jeff Sharkey
02bd78490d Reduce PackageInstaller I/O pressure.
When performing a restore during initial device setup, we could be
installing hundreds of packages.  Currently, we're writing all
metadata (including heavy icons) for every session mutation!  Because
we're holding the mSessions lock while writing all this heavy data,
we end up causing ANRs when apps call other PackageInstaller APIs.

This patch mitigates by moving the heavy icon data into separate
per-session PNG files, which we only persist when changed.

Bug: 17881962, 17567794
Change-Id: I4dee15d4a65a8eb65c381e6bb7477728b6cc30d2
2014-10-06 16:38:15 -07:00
Dianne Hackborn
2d7576b082 Fix issue #17752399: Multiple apps broken by GET_TASKS permission change
Keep around GET_TASKS as a permission available to apps, so apps still
think they have it and don't get all uppity because they don't.

Add a new REAL_GET_TASKS that is the actual permission now.

Plus some temporary compatibility code until everyone can transition
fromn GET_TASKS to REAL_GET_TASKS.

Change-Id: I12c1102eed24844685dcbd2fa3b612811603958f
2014-10-03 16:26:04 -07:00
Newton Allen
8f8a11b7fa Fix some documentation typos.
Change-Id: I747a0ade5c7b9c45d4465bf327952338bbc1cfaa
(cherry picked from commit 4465d1a03e)
2014-09-30 02:52:26 +00:00
Andres Morales
66b63cb825 Merge "Mark PDB identifier as SystemApi" into lmp-dev 2014-09-27 02:26:00 +00:00
Andres Morales
33df937f6f Mark PDB identifier as SystemApi
Had already marked the API itself as system api, just not
the Context.BLAH id. Also update the javadoc as it doesn't
return an FD anymore.

Change-Id: Ic8a5b8c75b0ba0bdf4ad26cf33d5f87eea568376
2014-09-26 17:08:59 -07:00
Jeff Sharkey
004a4b20f8 Include reason when wiping data.
This will help us track down who requested a data wipe.

Bug: 17412160
Change-Id: If8413e5d6377773f37e8b34ae3d26347226a027c
2014-09-24 13:58:09 -07:00
Jeff Sharkey
fb488eb2a2 Merge "More ACTION_CHOOSER ClipData migration." into lmp-dev 2014-09-23 23:58:51 +00:00
Jeff Sharkey
c004eef7bb More ACTION_CHOOSER ClipData migration.
Traverse into both EXTRA_INTENT and any EXTRA_INITIAL_INTENTS when
migrating extras to ClipData.  Also, we don't need to promote these
ClipData into the parent, since the platform ChooserActivity will
issue any required permission grants for the final user-selected
Intent.  Even if we wanted to, we can't combine the various child
Intent flags into anything meaningful at the ACTION_CHOOSER level.

Bug: 17580604
Change-Id: I6b5a1f572a7edf8135e059c67a2643d3736e40ab
2014-09-23 16:40:53 -07:00
Alan Viverette
fde4e3b17a Fix inaccurate TypedArray.getDrawable() documentation
The documentation implied that you could override
Resources.getDrawable(int) to load custom drawables, which is
not the case.

BUG: 16635905
Change-Id: I06c0febe2d6d4194ef5a31f167b378fe311b7a2d
2014-09-22 16:19:51 -07:00
Paul Soulos
628cb74d8a Fixes typo in Intent documentation
bug: 17583712
Change-Id: I37c77644213417751f8261098af44096aef51b14
2014-09-19 19:10:04 +00:00
Dianne Hackborn
ace27915d2 Fix issue #17564607: Apps in the managed profile can send any intent...
...to the primary user, even if it was not whitelisted to be forwarded.

The path where getActivityInfo is called for the ResolverActivity
would not correctly apply the requested user ID to the result, so
it wouldn't run under the correct user.

Change-Id: I1da47c54bbed26091832a28236d0b06762c92437
2014-09-18 19:01:01 -07:00
Alan Viverette
0adf32bc1e Fix parsing of old-style intent URIs
Improves bounds checking to restrict category matches to within the
category(...) item. Fixes CTS failure in IntentTest.testGetIntentOld().

BUG: 17557490
Change-Id: I1859fe18eaa881b771bab373d705d8fbeb6406c4
2014-09-18 12:53:16 -07:00
Jeff Sharkey
49c0e7375b Merge "Update API naming to follow style guide." into lmp-dev 2014-09-15 21:51:18 +00:00
Jeff Sharkey
de74231f24 Update API naming to follow style guide.
Bug: 17510755
Change-Id: If73d81b416355559592feb895a62132194f4ba62
2014-09-15 14:17:46 -07:00
Ihab Awad
1ec6888685 Add system feature for ConnectionService API support (1/3)
Bug: 17445268
Change-Id: Ibf52cb394f00d075afd07b883a91f00da84b3c85
2014-09-15 09:10:54 -07:00
Alan Viverette
c6a65dfbff Merge "Reduce instructions required to obtain and recycle TypedArray" into lmp-dev 2014-09-14 20:04:38 +00:00
Alan Viverette
8b5b25b448 Reduce instructions required to obtain and recycle TypedArray
Eliminates several field and method accesses by making the TypedArray
pool local to a single Resources object. Removes an unnecessary
synchronization.

ReadXmlAttrs averaged 0.069 ms/op before, 0.064 ms/op after.

BUG: 17484798
Change-Id: If790a5ba6596b47a04f117c8912974798a592052
2014-09-13 19:30:11 -07:00
Tyler Gunn
ef9f6f957d Renaming Telecomm to Telecom.
- Changing package from android.telecomm to android.telecom
- Changing package from com.android.telecomm to
com.android.server.telecomm.
- Renaming TelecommManager to TelecomManager.

Bug: 17364651
Change-Id: I192cb5d189f55db012ea72ee82ccc5aedbc21638
2014-09-12 22:16:17 -07:00
Amith Yamasani
1d653272a2 Rename and repurpose feature MANAGED_PROFILES to MANAGED_USERS
Bug: 17392243
Change-Id: I5ff0e70eeeeba264c96eaa2a17a6bd3669576c96
2014-09-12 16:45:33 -07:00
Kenny Guy
b6edee0dad Hide APIs renamed during API review of LauncherApps
Bug: 17390765
Change-Id: I79a979365005b13a2268b1cfe455241ae4fecb51
2014-09-12 11:44:58 +00:00
Amith Yamasani
e1e98741ff Merge "Annotate bindServiceAsUser with SystemApi" into lmp-dev 2014-09-11 23:48:37 +00:00
Amith Yamasani
c85029f7d9 Annotate bindServiceAsUser with SystemApi
Bug: 17470388
Change-Id: I0961e6ebabaffd91e3d152074b2f64ca4f9ba8fb
2014-09-11 16:47:17 -07:00
Craig Mautner
3969cabf59 Merge "If activity is an alias get maxRecents from target" into lmp-dev 2014-09-11 23:02:27 +00:00
Craig Mautner
8307ea701c If activity is an alias get maxRecents from target
Activity aliases do not pick up values in the PackageParser. The
actual values should come from the target activity instead.

Also ActivityInfo now propagates maxRecents in copy constructor
and across Binder calls (via parcelling).

Fixes bug 17391328.

Change-Id: I35d248032eca7557528c9d499b3b38f27c713d09
2014-09-11 15:53:44 -07:00
Alexandra Gherghina
ffb6343938 Merge "Bugfix: use the correct user for ContentResolver calls" into lmp-dev 2014-09-11 16:12:59 +00:00
Adam Connors
e107c3eb79 Remove package level intent forwarding.
Clean up unused methods.

Bug: 17389110
Change-Id: I8a80fe3e14219f06572de05c390cdda0efcbf5db
2014-09-11 15:42:13 +01:00
Dianne Hackborn
547f6e1803 Merge "Fix issue #17428001: Fix revokeUriPermissions" into lmp-dev 2014-09-11 00:55:25 +00:00
Dianne Hackborn
192679a7d3 Fix issue #17428001: Fix revokeUriPermissions
You can now revoke permissions that were granted to you.

Change-Id: I9a1872059edc715b10bbd2d653e45420d43331c3
2014-09-10 16:20:24 -07:00
Alexandra Gherghina
03e1e83697 Bugfix: use the correct user for ContentResolver calls
Bug: 16860604
Change-Id: I2de228442b7bd824a115f56a24d682d346737976
2014-09-10 18:13:12 +01:00
Adam Connors
c90f95c79d Merge "Add feature flags for verified boot and securely remove users." into lmp-dev 2014-09-10 10:07:15 +00:00
Adam Lesinski
732edf098f Merge changes I79ba54d7,I224fb4b6 into lmp-dev
* changes:
  Make UsageStats API default on only for the system
  ActivityManager shouldn't return null for getCurrentUser
2014-09-09 23:50:04 +00:00
Jeff Sharkey
ad5f44a68c Merge "Missing manifest error should be NO_CERTIFICATES." into lmp-dev 2014-09-09 22:44:52 +00:00
Jeff Sharkey
bc09755e19 Missing manifest error should be NO_CERTIFICATES.
When META-INF/MANIFEST.MF is missing, treat as NO_CERTIFICATES
instead of CERTIFICATE_ENCODING.  Also remove redundant layer of
debugging details when wrapping exceptions.

Bug: 15667982
Change-Id: I6e8216d5bf6e42da1feb70c89f991001380305be
2014-09-09 14:57:26 -07:00
Adam Lesinski
eddeb49a73 ActivityManager shouldn't return null for getCurrentUser
There was a race where ActivityManager would return null
for getCurrentUser() when switching between guest accounts.
This is because the Guest account was marked for deletion
while it was still active.

Bug:17290209

Change-Id: I224fb4b6836380e5acb7dbeb8f3343d74505f88a
2014-09-09 11:15:17 -07:00
Alexandra Gherghina
7677694320 Merge "Removing the NO_CROSS_PROFILE flag for intent forwarding" into lmp-dev 2014-09-09 17:45:36 +00:00
Alexandra Gherghina
c788487ae5 Removing the NO_CROSS_PROFILE flag for intent forwarding
Bug: 17435289
Change-Id: Iffbecd3cf9338a8633bfcc5bc47247bfc50e7546
2014-09-09 12:04:34 +01:00
Nicolas Prevot
f8a52c0667 Merge "Allowing a ContentProvider to have a null authority." into lmp-dev 2014-09-09 09:07:02 +00:00
Michael Wright
8e3b4d41e3 Merge "Add FEATURE_GAMEPAD." into lmp-dev 2014-09-08 23:21:49 +00:00
Michael Wright
6faa6759cd Add FEATURE_GAMEPAD.
This allows micro-consoles or other devices to signify that there's a
game controller in the box, even if the user hasn't connected it.

Change-Id: Ie5e2cf69f777ebe84abb83f34c9ed63d9555deff
2014-09-08 16:08:18 -07:00
Kenny Guy
d9037a48c6 Merge "Renaming of LauncherApps apis" into lmp-dev 2014-09-08 20:47:07 +00:00
Nicolas Prevot
6e412adaa7 Allowing a ContentProvider to have a null authority.
In this case, it will not be possible to query it with any uri.

BUG: 17414813

Change-Id: I76e8ad91539904f3c52b5a3436b2f1bd5e4d0fdf
2014-09-08 18:28:43 +01:00
Adam Connors
19ccb5fd75 Add feature flags for verified boot and securely remove users.
Bug: 17405636
Change-Id: I5e81cf02f8b3d5b98957019c76844875b491181c
2014-09-08 17:42:04 +01:00