summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorNikita Ioffe <ioffe@google.com>2019-03-27 22:59:28 +0000
committerNikita Ioffe <ioffe@google.com>2019-03-28 19:50:56 +0000
commit1962cb15129b34650739ad05b9a777a90b7aa336 (patch)
treea53e593d6b847fea1f24e7ca336760bedf47fa0a /tools/aapt2/java/JavaClassGenerator_test.cpp
parent319e7cb647c5ea473836276b6bddbc5f11e9a665 (diff)
staged sessions: clear INSTALL_ALLOW_DOWNGRADE if pre-reboot session did not have it
Note: this applies only to user builds. In case of staged sessions, post-reboot StagingManager creates new non-staged sessions to install apks. Since StagingManager is in system_server, those sessions will have INSTALL_ALLOW_DOWNGRADE flag enabled, even if original session did not have it (e.g. if it's created by Phonesky). This gives an installer an ability to downgrade an app by issuing a staged install. This CL fixes it by allowing downgrade only if one of the following applies: * It's a debuggable build. * Session was created by a system_server (RollbackManager use case). * Session was created by root or shell (adb development use case). Test: adb install foo_v2.apk && adb install --staged -d foo_v1.apk on user build Test: CtsStagedInstallHostTestCases (userdebug and user builds) Bug: 128409829 Fixes: 128409829 Change-Id: I2e5e8fd98584095b7d52891c88f033cb4c5caf70
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions