Merge \"Update CTS shims\" into nyc-dev
am: 6f140a249a
Change-Id: I46a95ea5eb9199c63e8f0a62ddf7c6eac149147d
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -62,6 +62,27 @@ LOCAL_FULL_MANIFEST_FILE := $(gen)
|
||||
|
||||
include $(BUILD_PACKAGE)
|
||||
|
||||
###########################################################
|
||||
# Variant: Privileged app upgrade w/ the wrong SHA
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
# this needs to be a privileged application
|
||||
LOCAL_PRIVILEGED_MODULE := true
|
||||
|
||||
LOCAL_MODULE_TAGS := optional
|
||||
LOCAL_SDK_VERSION := current
|
||||
LOCAL_PROGUARD_ENABLED := disabled
|
||||
LOCAL_DEX_PREOPT := false
|
||||
# anything to make this package's SHA different from CtsShimPrivUpgrade
|
||||
LOCAL_AAPT_FLAGS := --version-name WrongSHA
|
||||
|
||||
LOCAL_PACKAGE_NAME := CtsShimPrivUpgradeWrongSHA
|
||||
|
||||
LOCAL_MANIFEST_FILE := shim_priv_upgrade/AndroidManifest.xml
|
||||
|
||||
include $(BUILD_PACKAGE)
|
||||
|
||||
|
||||
###########################################################
|
||||
# Variant: System app
|
||||
|
||||
|
||||
@@ -7,12 +7,14 @@ NOTE: The need to include a binary on the system image may be deprecated if a
|
||||
solution involving a temporarily writable /system partition is implemented.
|
||||
|
||||
build:
|
||||
$ tapas CtsShim CtsShimPriv CtsShimPrivUpgrade
|
||||
$ tapas CtsShim CtsShimPriv CtsShimPrivUpgrade CtsShimPrivUpgradeWrongSHA
|
||||
$ m
|
||||
|
||||
local testing:
|
||||
$ cp $OUT/system/priv-app/CtsShimPrivUpgrade/CtsShimPrivUpgrade.apk \
|
||||
cts/hostsidetests/appsecurity/test-apps/PrivilegedUpdateApp
|
||||
$ cp $OUT/system/priv-app/CtsShimPrivUpgradeWrongSHA/CtsShimPrivUpgradeWrongSHA.apk \
|
||||
cts/hostsidetests/appsecurity/test-apps/PrivilegedUpdateApp
|
||||
$ cp $OUT/system/priv-app/CtsShimPriv/CtsShimPriv.apk \
|
||||
frameworks/base/packages/CtsShim
|
||||
$ cp $OUT/system/app/CtsShim/CtsShim.apk \
|
||||
|
||||
@@ -22,6 +22,9 @@
|
||||
<uses-sdk android:minSdkVersion="24"
|
||||
android:targetSdkVersion="24" />
|
||||
|
||||
<restrict-update
|
||||
android:hash="__CAN_NOT_BE_UPDATED__" />
|
||||
|
||||
<application
|
||||
android:hasCode="false"
|
||||
tools:ignore="AllowBackup,MissingApplicationIcon" >
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
<uses-sdk android:minSdkVersion="24"
|
||||
android:targetSdkVersion="24" />
|
||||
|
||||
<restrict-upgrade
|
||||
<restrict-update
|
||||
android:hash="__HASH__" />
|
||||
|
||||
<application
|
||||
|
||||
Reference in New Issue
Block a user