From b0292d7319aeab352cc455bdfc6f4542b69fda02 Mon Sep 17 00:00:00 2001 From: vvb2060 Date: Sun, 19 Sep 2021 00:38:33 +0800 Subject: [PATCH] Add execmem to allow hook --- native/jni/magiskpolicy/rules.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/native/jni/magiskpolicy/rules.cpp b/native/jni/magiskpolicy/rules.cpp index ea18d0b20..a78381df2 100644 --- a/native/jni/magiskpolicy/rules.cpp +++ b/native/jni/magiskpolicy/rules.cpp @@ -176,6 +176,10 @@ void sepolicy::magisk_rules() { // Allow Zygisk to prctl PR_SET_MM allow("zygote", "zygote", "capability", "sys_resource"); + // Allow hook + allow("zygote", "zygote", "process", "execmem"); + allow("system_server", "system_server", "process", "execmem"); + // Allow update_engine/addon.d-v2 to run permissive on all ROMs permissive("update_engine");