From fc40a4a777f0d780847cf0a6b4600afa1b6e1c07 Mon Sep 17 00:00:00 2001 From: kholoud mohamed Date: Wed, 17 Feb 2021 16:44:55 +0000 Subject: [PATCH] created FORCE_DEVICE_POLICY_MANAGER_LOG and CLEAR_FREEZE_PERIOD Created the following new permissions and granted it to shell: * FORCE_DEVICE_POLICY_MANAGER_LOG: will be used to expose DPM#forceNetworkLogs and DPM#forceSecurityLogs as TestAPIs. * CLEAR_FREEZE_PERIOD: will be used to expose DPM#clearSystemUpdatePolicyFreezePeriodRecord as a TestAPI. Bug: 180500227 Test: atest PermissionPolicyTest#platformPermissionPolicyIsUnaltered Merged-In: I8a2a49aa45704d8991e9cf3689b5259442fb1db3 Change-Id: I8a2a49aa45704d8991e9cf3689b5259442fb1db3 --- core/api/test-current.txt | 2 ++ core/res/AndroidManifest.xml | 10 ++++++++++ packages/Shell/AndroidManifest.xml | 2 ++ 3 files changed, 14 insertions(+) diff --git a/core/api/test-current.txt b/core/api/test-current.txt index 1d094c3d7f401..1762ebc7a3172 100644 --- a/core/api/test-current.txt +++ b/core/api/test-current.txt @@ -9,8 +9,10 @@ package android { field public static final String BRIGHTNESS_SLIDER_USAGE = "android.permission.BRIGHTNESS_SLIDER_USAGE"; field public static final String CHANGE_APP_IDLE_STATE = "android.permission.CHANGE_APP_IDLE_STATE"; field public static final String CLEAR_APP_USER_DATA = "android.permission.CLEAR_APP_USER_DATA"; + field public static final String CLEAR_FREEZE_PERIOD = "android.permission.CLEAR_FREEZE_PERIOD"; field public static final String CONFIGURE_DISPLAY_BRIGHTNESS = "android.permission.CONFIGURE_DISPLAY_BRIGHTNESS"; field public static final String CONTROL_DEVICE_LIGHTS = "android.permission.CONTROL_DEVICE_LIGHTS"; + field public static final String FORCE_DEVICE_POLICY_MANAGER_LOGS = "android.permission.FORCE_DEVICE_POLICY_MANAGER_LOGS"; field public static final String FORCE_STOP_PACKAGES = "android.permission.FORCE_STOP_PACKAGES"; field public static final String KEEP_UNINSTALLED_PACKAGES = "android.permission.KEEP_UNINSTALLED_PACKAGES"; field public static final String MANAGE_ACTIVITY_STACKS = "android.permission.MANAGE_ACTIVITY_STACKS"; diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml index 61e7d0ad9a73a..cea5d90f2fe85 100644 --- a/core/res/AndroidManifest.xml +++ b/core/res/AndroidManifest.xml @@ -2556,6 +2556,16 @@ android:label="@string/permlab_manageProfileAndDeviceOwners" android:description="@string/permdesc_manageProfileAndDeviceOwners" /> + + + + + + diff --git a/packages/Shell/AndroidManifest.xml b/packages/Shell/AndroidManifest.xml index b7ce2a30931be..2662437c8f27a 100644 --- a/packages/Shell/AndroidManifest.xml +++ b/packages/Shell/AndroidManifest.xml @@ -122,6 +122,8 @@ + +