Trust Issues
EasyMobile Security
Overview
You're given an APK that checks whether the user is an admin before revealing a hidden string. Explore how the app verifies admin status and find a way to bypass this check to access the secret.
flag format:
flag{***_*****_*****}
Lab Details
Prerequisites & Requirements
- Android Application Logic:
- Understanding basic Java/Kotlin control flow (if/else statements) and how boolean checks determine app behavior.
- Familiarity with the structure of an Android Activity and identifying methods that act as "Gatekeepers" (
e.g., is_admin).
- Frida JavaScript API:
- Proficiency in the syntax for Method Replacement .
- Understanding how to access a specific class using
Java.use("package.name.ClassName") and how to overwrite a method's implementation.
- Static vs. Dynamic Analysis:
- Understanding the difference between decompiling an APK to read code (Static) and modifying its behavior while it runs in memory (Dynamic).
What will you learn?
- Runtime Logic Bypassing:
- Learning how to subvert application security controls without modifying the APK file itself (no re-compiling or signing required).
- Implementing Boolean Spoofing : Forcing a specific function (is_admin) to always return true, regardless of the actual internal logic.
- Frida Method Hooking:
- Mastering the .implementation override technique.
- Understanding how to intercept a function call, execute custom logic (like logging to the console), and define a custom return value.
- Accessing Protected Content:
- Triggering hidden functionality (the call to stringFromJNI) that is otherwise unreachable via normal user interaction.
Tools
- JADX (Dex to Java Decompiler):
- Used for Static Analysis . It allows you to inspect the MainActivity source code to find the package name (
com.titoot.areyouadmin) and identify the exact method name (is_admin) that needs to be bypassed.
- Used for Static Analysis . It allows you to inspect the MainActivity source code to find the package name (
- Frida:
- Used for Dynamic Instrumentation .
- It executes the JavaScript payload that hooks into the running application process.
- It allows you to dynamically rewrite the is_admin function in memory, effectively making the application "trust" you as an administrator instantly.
Job Positions
Mobile Security Engineer
Tags
Static AnalysisDynamic AnalysisDecompilerHookingCode FlowFunction ProbesApi Calls