Require permission to unlock keyguard
Bug: 288896339 Test: Manual, verify that the app which can be found on the bug can no longer call keyguardGoingAway successfully Change-Id: I7ba7e56f954c8e6f1f734311f735215918975bc6 Require permission to unlock keyguard Bug: 288896339 Test: Manual, verify that the app which can be found on the bug can no longer call keyguardGoingAway successfully Change-Id: I7ba7e56f954c8e6f1f734311f735215918975bc6
This commit is contained in:
@@ -236,6 +236,7 @@ interface IActivityTaskManager {
|
||||
* {@link android.view.WindowManagerPolicyConstants#KEYGUARD_GOING_AWAY_FLAG_TO_SHADE}
|
||||
* etc.
|
||||
*/
|
||||
@JavaPassthrough(annotation="@android.annotation.RequiresPermission(android.Manifest.permission.CONTROL_KEYGUARD)")
|
||||
void keyguardGoingAway(int flags);
|
||||
|
||||
void suppressResizeConfigChanges(boolean suppress);
|
||||
|
||||
@@ -18,6 +18,7 @@ package com.android.server.wm;
|
||||
|
||||
import static android.Manifest.permission.BIND_VOICE_INTERACTION;
|
||||
import static android.Manifest.permission.CHANGE_CONFIGURATION;
|
||||
import static android.Manifest.permission.CONTROL_KEYGUARD;
|
||||
import static android.Manifest.permission.CONTROL_REMOTE_APP_TRANSITION_ANIMATIONS;
|
||||
import static android.Manifest.permission.DETECT_SCREEN_CAPTURE;
|
||||
import static android.Manifest.permission.INTERACT_ACROSS_USERS;
|
||||
@@ -3549,6 +3550,7 @@ public class ActivityTaskManagerService extends IActivityTaskManager.Stub {
|
||||
|
||||
@Override
|
||||
public void keyguardGoingAway(int flags) {
|
||||
mAmInternal.enforceCallingPermission(CONTROL_KEYGUARD, "unlock keyguard");
|
||||
enforceNotIsolatedCaller("keyguardGoingAway");
|
||||
final long token = Binder.clearCallingIdentity();
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user