History log of /frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
3accca05ddcad9d0b1b313eae49f273e39121d3c 20-Sep-2013 Dianne Hackborn <hackbod@google.com> Add major version code to platform.

It turns the version code into almost a 64-bit integer, with the
new major part being the upper 32 bits.

The only tricky part about this is the backup manager, since it
stored 32-bit version codes in its backup data sets. This is dealt
with by, when the major version code is not 0, writing MIN_INT as
the version code and following that by the full long version code,
which we can detect when reading. Note that this makes backup sets
containing apps with major version codes incompatible with older
versions of the platform.

Bug: 64459786
Test: Added in Change-Id: Iab8a682b62103babd6c16a56b8dc1e97d7078658
Change-Id: Ibfffe235bbfcf358b3741abd3f7197fdb063d3f3
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
4fd8aa51e4de5a7c93841571e30ff10077d1b125 19-Sep-2017 Torne (Richard Coles) <torne@google.com> Consider shared libs when precreating WebView classloader.

The change to handling of the deprecated Apache HTTP library means that
the WebView implementation package might have a non-empty shared library
list. Make sure to fetch shared libraries when querying WebView
implementations, and take them into account when constructing both the
actual classpath to be used to precreate the classloader, and when
deciding what the cache key for the precreated classloader should be.

Change-Id: I5e1409358d935e1c9f325db434bc6d4ef8ead759
Fixes: 65574359
Test: launch anything that uses WebView
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
b2b992531c0fcbec5407c96ddd372afd134abcc9 08-Jun-2017 Torne (Richard Coles) <torne@google.com> Disable multiprocess WebView for 32-bit lowram devices.

Multiprocess WebView uses additional RAM; don't enable it for lowram
32-bit devices. 64-bit devices always use multiprocess regardless of the
amount of RAM, since multiprocess is often a net memory saving on those
devices due to the ability to run a 32-bit renderer process.

Bug: 62217217
Test: Run dumpsys webviewupdate on Android Go and check status.
Change-Id: I67e462beca2c7f62ef7cde821df80ce13ebd4398
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
db70ba2953bbb6d5c5d3e2a31b4170c287ab0441 24-Jan-2017 Torne (Richard Coles) <torne@google.com> Enable multiprocess WebView by default.

Make the multiprocess WebView enabled by default. It can be disabled by
the user in developer settings, but will be re-enabled after the WebView
implementation is updated to keep people testing it.

Bug: 21643067
Test: verify that WebView is enabled by default in developer settings
Change-Id: I100dac6b4d3784678a694352faa6e9fb2fc72078
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
dc375072c4fc95d612ccd3c60ff0519eb75b804c 11-Jan-2017 Torne (Richard Coles) <torne@google.com> Prepare to enable multiprocess by default.

Implement logic to track the version on which the user last manually
enabled/disabled multiprocess (by storing the version code in the
setting, negated for disabled). This enables us to have the following
logic:

1) If multiprocess is enabled by default, re-enable it for users who
turned it off on a previous version, but leave it off for users who
turned it off on the current version. This lets us collect fresh
bug reports after fixing previous issues.

2) If multiprocess is disabled by default, leave it on for users who
have enabled it manually, but turn it back off for users who were
just relying on the default.

This CL leaves it set to "disabled by default" so there is no immediate
behavioural change, but this enables us to switch the "enabled by
default" flag back and forth freely later.

Bug: 21643067
Test: run WebViewUpdateServiceTest
Test: manually upgrade/downgrade webview, verify behaviour of setting
Change-Id: Ibbecac7e5ee75e9c4a1b6efb84253ace98d1eb1a
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
364e16029017a4e16ed727a5e501f70363d04e5a 14-Dec-2016 Gustav Sennton <gsennton@google.com> Change WebView fallback mechanism to consider all users' package states.

MultiProcess WebView will use a Service to start a separate process (the
renderer process). This Service can only be started if the WebView
package is enabled for the current user. To ensure that the current
WebView package is usable by all users on a single device we now only
use a WebView package as WebView implementation if that package is
enabled and installed for all user on the device. This also means that
the WebView-fallback mechanism will trigger when disabling the primary
WebView package for any user (not just the system user).

Also add multi-user unit tests to cover this new change.

Bug: 32894152
Test: run unit tests in WebViewUpdateServiceTest
Test: ensure the standalone WebView package becomes enabled (for all
device users) when disabling Chrome for a secondary user.
Test: load WebView (both using Monochrome, and using the standalone
WebView).

Change-Id: Iad3fc48aa50273062c2f29ae48a343c2dea38116
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
1a4c4e35397adb964fb53695f66e1ac1ace39ff1 10-Jan-2017 Torne (Richard Coles) <torne@google.com> Handle multiprocess flag in WebView update service.

Instead of letting DevelopmentSettings manage the setting directly and
observing the changes from WebViewUpdateService, have the update service
manage the setting and just expose IPCs for the settings app to use to
get/set the setting. This means we can set a more flexible policy for
whether multiprocess is enabled by default and change it without
touching the settings code, though for now this CL does not change the
behaviour and is just a refactoring.

Bug: 21643067
Test: Toggle multiprocess WebView in developer settings
Change-Id: I3057c09d99f5f6f472a5195a8e14e9164ea5733a
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
0d1fd8d09163566d2c7eb72037f63b6404ada642 12-Oct-2016 Amith Yamasani <yamasani@google.com> Secure MATCH_UNINSTALLED_PACKAGES across users

Introduce a new internal flag MATCH_ANY_USER for genuine uses
of searching through all apps on the device.

Some temporary accommodations for Launchers that reach across
to the work profile until we have a new LauncherApps API to do
that officially.

Bug: 31000380
Test: CTS tests added
Change-Id: I2e43dc49d6c2e11814a8f8d1eb07ef557f31af34
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
dc589ac82b5fe2063f4cfd94c8ae26d43d5420a0 11-Nov-2016 Sudheer Shanka <sudheersai@google.com> Update usage of ActivityManagerNative.

- Remove references to ActivityManagerProxy.
- Add isSystemReady to ActivityManager.

Bug: 30977067
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test android.server.cts
adb shell am instrument -e class com.android.server.am.ActivityManagerTest,com.android.server.am.TaskStackChangedListenerTest \
-w com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner
Change-Id: I07390b6124fb1515821f5c0b37baf6ae74adc8fa
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
86f7bbe134a274a4936b73e2fc2287482ac0157e 24-Oct-2016 Gustav Sennton <gsennton@google.com> Fix WebViewUpdateServiceTest failures when using Thread without Looper.

Add some more methods to SystemInterface to avoid calling into the rest
of the framework from WebViewUpdateServiceTests.

Also convert WebViewUpdateServiceTest to use non-deprecated test
utilities.

Test: make sure tests in WebViewUpdateServiceTest pass.
Bug: 32364900
Change-Id: I8cf67568bb7e551e1c011028e0bb4e15c0e9f2bb
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
ded209843616a98e6f97db0d1784f6d630cbd5e9 15-Aug-2016 Robert Sesek <rsesek@google.com> Create the WebViewZygote and implement WebViewZygoteInit.

This adds a new init-spawned daemon, webview_zygote, that starts a JVM and
acts as a zygote process for WebView isolated_app services.

Test: m
Test: angler boots
Test: Turn on Settings>Developer>Multiprocess Webview. webview_zygote32 or
webview_zygote64 start (requires dependent CLs).

Bug: 21643067
Change-Id: Ida98bd04b4d77736b672b03af651c4eb97ce88c1
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
0df2c5566a9d7d71ca84cb072114f051bbe7a344 14-Jun-2016 Gustav Sennton <gsennton@google.com> Support using uninstalled WebView packages as WebView implementation.

A package can be uninstalled for the system user but still be installed
on the device. Currently, we do not use such a package as WebView
implementation which means we fall back to using the fallback WebView
package.
However, if the fallback package is not valid (because it needs to be
updated first) loading WebView will fail.

With this change we fetch allow the fetching of information from
packages that are uninstalled for the system user so that we can still
load WebView when the only valid WebView provider is uninstalled for the
system user.

Also listen to package additions/changes/removals for all users -
otherwise we won't notice when a package becomes replaced if it was
already uninstalled for the system user.

Bug: 29321185
Change-Id: Ia23c4493844877aea1b4eab7e666fd37540c4f97
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
9455bd0105f974de3d1164890353c2a0d0605840 08-Apr-2016 Hui Shu <hush@google.com> Cache the parsed result of WebView provider config xml

BUG: 27736084
Change-Id: I3665a5fd4777d22c6f217b358195edbeaad3bb1d
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
c0bc993801ae1296c8338b5fd971743309fde924 13-Apr-2016 Gustav Sennton <gsennton@google.com> Ensure at least one default-available webview package is a non-fallback

Parts of the WebViewUpdateService code assume that there exists at
least one webview package which is available by default and is not a
fallback package. With this CL we enforce this assumption by crashing
when parsing the webview packages config file if it doesn't hold.

Bug: 28014401
Change-Id: Ib7de1f596e31bae65542a6883a9f3af54337bf1b
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
631de99ef99dddde939aa5132e89625e35e77046 07-Apr-2016 Gustav Sennton <gsennton@google.com> Add more checks for invalid states when reading webview packages config.

There should be at least one available-by-default package (otherwise the
user would have to explicitly choose webview implementation before using
webview). Furthermore a fallback package should always be available by
default (otherwise it would have to be chosen by the user to be used
after being enabled).

Bug: 28014401
Change-Id: I90c300898a5be4219317d65f15878e1d421193d7
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
ff396f2710e60a4c596e30c7dc74ad7ef24a7ecc 08-Apr-2016 Gustav Sennton <gsennton@google.com> Ensure we don't crash the system server when disabling/enabling package.

We shouldn't crash when trying to disable/enable a non-existent fallback
package.

Bug: 27918467
Change-Id: Ia94425ac197b17430900bb7a9e7b2d2bf65ab9b3
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
5c153c5172a59e8a3d5cd0cb66df669b3ac79ece 06-Apr-2016 Gustav Sennton <gsennton@google.com> Disable fallback webview package before downgrading it.

Now that we support disabling packages before downgrading them we can
do this for the webview fallback mechanism to avoid disabling a fallback
asynchronously (downgrading a package is an asynchronous operation).

We also check that the package is an upgraded app before downgrading it,
to not try to downgrade it unnecessarily.

Bug: 27894939

Change-Id: I541c2fcfe8016e4bcc2d5afff6e393c81e2749a2
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
9e8c0584faae06ad903b8b859c5a5e5b11d63257 25-Mar-2016 Hui Shu <hush@google.com> Disallow WebView provider packages lower version than Chrome Stable

Doing so has security benefits, making sure the device is at least as secure as
the MonoChrome Stable on the system image.

This is implemented as checking WebView provider package versionCode against the
default available, non-fallback WebView provider package. On GMS devices, this
is MonoChrome Stable. On AOSP devices, this is standalone WebView.

BUG: 27469181
Change-Id: Id5b68ee28401a24843421cfcc3755e63196ac0f9
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java
065b7e6ef588a11c82cee22012706e6c0e66d0a3 01-Apr-2016 Gustav Sennton <gsennton@google.com> Move more code from WebViewUpdateService to separate overridable class

Move more code from WebViewUpdateService to utility classes (methods
handling settings and uninstalling/enabling/disabling packages) to be
overridden during tests.

Also rename system utility class.

Bug: 27635535

Change-Id: If49999fba4fd0962f103f389898fa5ddf19365bd
/frameworks/base/services/core/java/com/android/server/webkit/SystemImpl.java