Mobile Security
Mobile application security testing involves analyzing the application binary (static analysis), interacting with the running application (dynamic analysis), and intercepting network traffic.
Mobile Pentesting Methodology
1. Reconnaissance
App Store, Permissions, Architecture
2. Static Analysis
Decompile, Code Review, Secrets
3. Dynamic Analysis
Frida, Runtime Hooking, Bypass
4. Network Analysis
Proxy, SSL Pinning, API Testing
5. Data Storage
Keychain, SharedPrefs, SQLite
What You'll Learn
- APK/IPA static analysis
- Dynamic instrumentation with Frida
- Root/jailbreak detection bypass
- SSL/TLS pinning bypass
- Insecure data storage attacks
- IPC and deep link exploitation
- Biometric authentication bypass
- Cross-platform framework testing
Platforms
Android
APK analysis, decompilation, root detection bypass, and dynamic instrumentation.
iOS
IPA decryption, Objective-C/Swift analysis, keychain dumping, and Frida hooking.
Advanced Topics
Certificate Pinning
SSL/TLS pinning bypass techniques
Local Storage
Insecure data storage vulnerabilities
IPC Attacks
Intent, deep links, URL schemes
Biometric Bypass
Fingerprint & Face ID attacks
Cross-Platform
Flutter, React Native, Xamarin
Data Storage Locations
| Storage Type | Android | iOS | Risk Level |
|---|---|---|---|
| Secure Storage | Android Keystore | Keychain Services | Low |
| Preferences | SharedPreferences | NSUserDefaults | Medium |
| Database | SQLite / Room | Core Data / SQLite | Medium |
| Files | /data/data/app/files/ | Documents/Library | Medium |
| External Storage | /sdcard/ | N/A | High |
| Cache | /data/data/app/cache/ | Caches/ | High |
| Logs | logcat | Console.app | High |
Quick Setup
Testing Environment
Android Setup
# Install core tools
pip install frida-tools objection
# Start emulator with writable system
emulator -avd Pixel_API_30 -writable-system
# Push Frida server
adb push frida-server /data/local/tmp/
adb shell chmod 755 /data/local/tmp/frida-server
adb shell /data/local/tmp/frida-server &iOS Setup
# Install tools (macOS)
brew install libimobiledevice ideviceinstaller
# On jailbroken device, add Frida repo:
# https://build.frida.re
# Connect and verify
idevice_id -l
frida-ps -UOWASP Mobile Top 10
Cross-Platform Tools
Frida
InstrumentationDynamic instrumentation toolkit for developers, reverse-engineers, and security researchers.
Installation
pip install frida-toolsObjection
InstrumentationA runtime mobile exploration toolkit, powered by Frida.
Installation
pip install objectionMobSF
AnalysisMobile Security Framework - automated all-in-one mobile application pen-testing framework.
Installation
docker run -p 8000:8000 opensecurity/mobile-security-framework-mobsfBurp Suite
ProxyThe standard for intercepting and modifying HTTP/HTTPS traffic from mobile apps.
Installation
# Download from websiteDrozer
AndroidComprehensive security assessment framework for Android. Test IPC endpoints and content providers.
Installation
pip install drozerGhidra
Reverse EngineeringNSA's software reverse engineering framework. Excellent for native library analysis.
Installation
# Download from websiteLegal Disclaimer