From 8b095de04d5e615827ef75a1259398193805bec0 Mon Sep 17 00:00:00 2001 From: vvb2060 Date: Sat, 23 Jul 2022 18:06:04 +0800 Subject: [PATCH] Fix app_zygote context --- native/jni/zygisk/deny/utils.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/native/jni/zygisk/deny/utils.cpp b/native/jni/zygisk/deny/utils.cpp index 3213bf5a7..051643c01 100644 --- a/native/jni/zygisk/deny/utils.cpp +++ b/native/jni/zygisk/deny/utils.cpp @@ -124,7 +124,7 @@ static bool proc_context_match(int pid, string_view context) { sprintf(buf, "/proc/%d/attr/current", pid); if (auto fp = open_file(buf, "re")) { fgets(buf, sizeof(buf), fp.get()); - if (str_eql(buf, context)) { + if (str_starts(buf, context)) { return true; } } @@ -359,7 +359,7 @@ int enable_deny() { if (SDK_INT >= 29 && zygisk_enabled) { kill_process("usap32", true); kill_process("usap64", true); - kill_process<&proc_context_match>("app_zygote", true); + kill_process<&proc_context_match>("u:r:app_zygote:s0", true); } }