diff options
author | Park Ju Hyung <qkrwngud825@gmail.com> | 2020-03-13 01:32:27 +0900 |
---|---|---|
committer | alk3pInjection <webmaster@raspii.tech> | 2021-09-27 21:17:05 +0800 |
commit | d1bc701d4f7a72cf5b7e32d780edfa68c3655fd9 (patch) | |
tree | e57bab0e02f3582e6ac9e442c69f78c583fbe1bf | |
parent | af8d2068eda5240f50b0c5ebd8bcb13c662a78f1 (diff) |
[aospa][quartz] VibratorService: bypass AppOps check
AppOps is randomly rejecting vibration calls from SystemUI.
Bypass this check entirely to workaround it.
This introduces a potential security issue where apps without
android.permission.VIBRATE would be able to send vibrations,
but the existing issue directly affects UX and outweighs the
potential security issue.
Change-Id: I5cc80eda2dbfe4a5baab95e961e98717ed5457f1
Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>
-rw-r--r-- | services/core/java/com/android/server/VibratorService.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/services/core/java/com/android/server/VibratorService.java b/services/core/java/com/android/server/VibratorService.java index 997331959a5c..6598191fe4cc 100644 --- a/services/core/java/com/android/server/VibratorService.java +++ b/services/core/java/com/android/server/VibratorService.java @@ -1163,6 +1163,8 @@ public class VibratorService extends IVibratorService.Stub return false; } + // XXX: AppOps is randomly rejecting vibration calls from SystemUI + /* final int mode = getAppOpMode(vib.uid, vib.opPkg, vib.attrs); if (mode != AppOpsManager.MODE_ALLOWED) { if (mode == AppOpsManager.MODE_ERRORED) { @@ -1172,6 +1174,7 @@ public class VibratorService extends IVibratorService.Stub } return false; } + */ return true; } |