From d171993597c6f2977561dfe4a87227bb854c0a96 Mon Sep 17 00:00:00 2001 From: Hinnli Date: Tue, 20 Oct 2026 04:23:43 +0300 Subject: [PATCH] Use ShadowHook MULTI mode for mod hook chains --- app/src/main/cpp/Core/Cipher/CipherHook.cpp | 4 ++-- app/src/main/cpp/main.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/cpp/Core/Cipher/CipherHook.cpp b/app/src/main/cpp/Core/Cipher/CipherHook.cpp index 0f5f9b4..ff8c8b5 100644 --- a/app/src/main/cpp/Core/Cipher/CipherHook.cpp +++ b/app/src/main/cpp/Core/Cipher/CipherHook.cpp @@ -64,7 +64,7 @@ CipherHook* CipherHook::Fire() { } else if (pInstance->get_address() == this->get_address() && pInstance->m_type == Types::e_hook) { const auto prior = Cipher::DescribePatchesAt(get_address()); - LOGI("Cipher: hook chain at %p - prior=%s, new=%s (coexisting shared hook)", + LOGI("Cipher: hook chain at %p - prior=%s, new=%s (coexisting multi hook)", (void*)get_address(), prior.empty() ? "" : prior.front().ownerModule.c_str(), CipherInternal::ResolveOwnerForLog(callerPC).c_str()); @@ -81,7 +81,7 @@ CipherHook* CipherHook::Fire() { uint32_t hook_flags = this->get_Lock() ? SHADOWHOOK_HOOK_WITH_UNIQUE_MODE - : SHADOWHOOK_HOOK_WITH_SHARED_MODE; + : SHADOWHOOK_HOOK_WITH_MULTI_MODE; this->stub = shadowhook_hook_func_addr_2( (void *)this->get_address(), diff --git a/app/src/main/cpp/main.cpp b/app/src/main/cpp/main.cpp index 6ae641f..0c5dea7 100644 --- a/app/src/main/cpp/main.cpp +++ b/app/src/main/cpp/main.cpp @@ -226,7 +226,7 @@ static void install_chat_fix() { __unused __attribute__((constructor)) int main() { LOGI("Starting Sky ModMenu.. Build time: " __DATE__ " " __TIME__); - shadowhook_init(SHADOWHOOK_MODE_SHARED, false); + shadowhook_init(SHADOWHOOK_MODE_MULTI, false); Canvas::libName = "libBootloader.so"; do { sleep(1);