| name | objection-android-pentest |
| description | Use Objection for runtime Android mobile app exploration and security testing. Use this skill whenever the user needs to perform dynamic analysis on Android apps, bypass SSL pinning, disable root detection, hook methods, inspect memory, or explore app internals at runtime. Trigger for any Android pentesting task involving Frida, runtime manipulation, or mobile security assessment. |
Objection Android Pentest Skill
A skill for using Objection to perform runtime exploration and security testing on Android applications.
What Objection Does
Objection is a runtime mobile exploration toolkit powered by Frida. It lets you:
- Bypass security controls (SSL pinning, root detection)
- Hook and inspect methods at runtime
- Explore app internals without decompiling
- Manipulate app behavior dynamically
- Inspect memory, SQLite databases, and more
Important: Objection does NOT bypass jailbreak/root restrictions. You're still limited by the device's sandbox.
Setup
Installation
pip3 install objection
Connection Requirements
- ADB Connection: Establish a regular ADB connection to the device
- Frida Server: Start Frida server on the device and verify it's working
- Target App: Identify the app package name using
frida-ps -Uai
Starting Objection
objection --gadget <package.name> explore
objection explore
Common Workflows
1. Environment Exploration
Gather initial reconnaissance about the app environment:
env
frida
2. Security Control Bypass
Disable SSL Pinning
android sslpinning disable
Disable Root Detection
android root disable
android root simulate
3. App Structure Discovery
List Components
android hooking list activities
android hooking list services
android hooking list receivers
Get Current Activity
android hooking get current_activity
Search Classes
android hooking search classes <package.name>
android hooking list classes
Search Methods
android hooking search methods <package.name> <ClassName>
android hooking list class_methods <package.name>.<ClassName>
4. Method Hooking
Watch a Single Method
android hooking watch class_method <package.name>.<Class>.<method> \
--dump-args \
--dump-backtrace \
--dump-return
Watch an Entire Class
android hooking watch class <package.name>.<Class> \
--dump-args \
--dump-return
Warning: Hooking entire classes can crash the application. Use with caution.
Modify Return Values
To force a method to return a specific value:
android hooking watch class_method <package.name>.<Class>.checkPin \
--return true
5. Memory Operations
Dump Memory
memory dump all <local_destination>
memory dump from_base <base_address> <size_to_dump> <local_destination>
List Modules
memory list modules
Search and Write
memory search "<hex_pattern>" --string --offsets-only
memory write "<address>" "<hex_pattern>" --string
6. Class Instances
android heap print_instances <fully.qualified.ClassName>
7. Keystore and Intents
android keystore list
android intents launch_activity
android intent launch_service
8. SQLite Database Access
sqlite
9. File Operations
file download <remote_path> [<local_path>]
file upload <local_path> [<remote_path>]
10. Screenshots
android ui screenshot /tmp/screenshot
android ui FLAG_SECURE false
11. Shell Commands
android shell_exec <command>
File Transfer
import <local_path_to_frida_script>
Exit
exit
Best Practices
- Static Analysis First: Use static analysis to identify targets before dynamic hooking
- Start Small: Hook individual methods before entire classes
- Watch for Crashes: Extensive hooking can destabilize the app
- Document Findings: Keep track of hooked methods and their behavior
- Use Scripts: For repetitive tasks, create custom Frida scripts
Limitations
- Hooking methods can crash applications (Frida limitation)
- Cannot call instance methods directly on discovered objects
- Cannot create new class instances through Objection
- No built-in crypto method hooking shortcuts
References