Mobile Application Security Testing: Android and iOS MAST Guide for Security Practitioners
Mobile applications present a security testing challenge distinct from web applications: the attack surface spans the binary itself, local device storage, inter-app communication, network traffic, and backend APIs -- all within a sandboxed environment designed to resist analysis. Unlike a web application where the server is the target, mobile security testing requires analyzing the client (the app binary), the transport layer (the API traffic), and the server simultaneously. This guide covers the full MAST methodology: static analysis of the app binary, dynamic analysis of runtime behavior, traffic interception and API testing, and the most common vulnerability classes that cause mobile app security failures in enterprise environments.
OWASP Mobile Top 10 2024: The Testing Baseline
The OWASP Mobile Top 10 (updated in 2024) provides the standard vulnerability taxonomy for mobile application security assessment.
M1: Improper Credential Usage Hardcoded credentials, API keys, and tokens embedded in the app binary or configuration files. These are extractable by anyone who decompiles the APK or examines the IPA. Every mobile security assessment should include a credential scan of the decompiled source.
M2: Inadequate Supply Chain Security Vulnerable third-party SDKs, malicious libraries, and dependency chain attacks. Mobile apps average 30+ third-party SDKs; each is an attack surface. Test by extracting the app's dependency list and checking each SDK version against known CVEs.
M3: Insecure Authentication and Authorization Weak authentication mechanisms, missing certificate pinning, broken session management, and insecure direct object references in API calls. Mobile apps frequently implement their own authentication logic rather than using platform-provided mechanisms, introducing errors.
M4: Insufficient Input and Output Validation Injection vulnerabilities in local SQLite databases, JavaScript injection in WebViews, path traversal in file operations, and XSS in hybrid apps. WebView security is particularly important: a WebView with JavaScript enabled and addJavascriptInterface can expose native device capabilities to injected JavaScript.
M5: Insecure Communication Missing certificate validation, acceptance of self-signed certificates, cleartext HTTP traffic, and weak TLS configuration. MITM attacks against improperly validated connections are a primary mobile attack vector.
M6: Inadequate Privacy Controls Excessive permission requests, logging of sensitive data, and unintentional data sharing with analytics SDKs. Many mobile apps log authentication tokens or PII to system logs accessible by other apps on rooted devices.
M7: Insufficient Binary Protections Missing root/jailbreak detection, missing debugger detection, missing obfuscation, and missing integrity checks. Without these controls, attackers can repackage apps with malicious modifications or dynamically analyze the app in a controlled environment.
M8: Security Misconfiguration Misconfigured Android permissions in AndroidManifest.xml, over-permissioned iOS entitlements, exported Android components (activities, services, providers) accessible to other apps, and debug configurations left in production builds.
M9: Insecure Data Storage Sensitive data in SharedPreferences (Android), NSUserDefaults (iOS), SQLite databases, external storage, or temporary files without encryption. This remains one of the most commonly found vulnerabilities across mobile apps.
M10: Insufficient Cryptography Use of deprecated algorithms (MD5, SHA1, DES, RC4), hardcoded encryption keys, predictable IV values, and ECB mode encryption. Crypto errors often produce data that looks encrypted but is trivially decryptable.
Android vs iOS Attack Surface Differences
Android and iOS have fundamentally different security architectures that shape what you test and how.
Android unique attack surfaces:
- Exported components: Android activities, services, content providers, and broadcast receivers declared with
android:exported="true"in AndroidManifest.xml are accessible to other apps on the device. Test exported components for injection, unauthorized access to data providers, and privilege escalation via intent redirection. - Deep links and intent handling: Android deep links and intent filters can be exploited by malicious apps to launch exported activities with crafted parameters. Test all deep link handlers for open redirect and data injection vulnerabilities.
- External storage: Android apps that write sensitive data to external storage (
/sdcard/) expose it to any other app with READ_EXTERNAL_STORAGE permission (or no permission on Android 10+ shared media). Scan for writes to external storage paths. - APK analysis: Android APKs are ZIP archives containing compiled Dalvik bytecode (.dex files). Tools like jadx, apktool, and JADX-GUI can decompile the bytecode to readable Java-like source, making static analysis straightforward without access to the original source code.
- Accessibility services abuse: Android accessibility services APIs, while designed for assistive technology, are frequently abused by banking trojans to read screen content, simulate taps, and intercept credentials.
iOS unique attack surfaces:
- Keychain access groups: The iOS Keychain is the correct mechanism for storing credentials, but misconfigured kSecAttrAccessible values (particularly kSecAttrAccessibleAlways) make keychain items accessible even on locked devices. Test keychain storage for overly permissive accessibility attributes.
- URL scheme hijacking: iOS URL scheme handlers can be registered by multiple apps. A malicious app can register the same URL scheme as a legitimate app and intercept deep links containing OAuth tokens or other sensitive parameters.
- Universal links vs. custom URL schemes: Universal links (HTTPS-based) are more secure than custom URL schemes because they require the app to be registered as the verified handler for the domain. Test whether the app uses universal links for sensitive operations rather than custom URL schemes.
- Binary analysis on iOS: Without jailbreak, static analysis requires the encrypted IPA from the App Store to be decrypted first. Tools like frida-ios-dump can extract a decrypted IPA from a running device. Alternatively, developers can use debug builds for testing.
Briefings like this, every morning before 9am.
Threat intel, active CVEs, and campaign alerts, distilled for practitioners. 50,000+ subscribers. No noise.
Static Analysis: Extracting and Analyzing the App Binary
Static analysis examines the app binary without executing it. For Android, this means decompiling the APK; for iOS, it means analyzing the decrypted IPA binary and extracting embedded resources.
MobSF (Mobile Security Framework) is the most widely used open-source MAST platform. It performs automated static and dynamic analysis for Android APKs, iOS IPAs, and Windows App packages. Install it with Docker (docker run -it --rm -p 8000:8000 opensecurity/mobile-security-framework-mobsf) and upload the app binary through the web interface. MobSF generates:
- AndroidManifest.xml analysis (dangerous permissions, exported components, debug flags)
- Hardcoded secrets scan (API keys, credentials, cryptographic keys)
- Dangerous API usage (reflection, exec(), crypto function calls)
- Certificate analysis
- Malware pattern matching
- CVSS-scored findings report
jadx is the most capable Android decompiler for manual analysis. After running MobSF for automated findings, use jadx-gui to browse the decompiled Java source and investigate specific areas MobSF flagged. Focus areas for manual review: authentication logic, cryptographic implementations, SQLite query construction (injection risk), WebView configuration, and network request handling.
Critical checks in AndroidManifest.xml:
android:debuggable="true"on production buildsandroid:allowBackup="true"(enables backup of app data via ADB without root)android:exported="true"on components that should be internal- Missing
android:permissionattributes on exported content providers - Broad intent filters on sensitive activities
Dynamic Analysis and Traffic Interception
Dynamic analysis tests the app while it runs, capturing API traffic, monitoring file system operations, and hooking into function calls at runtime.
Traffic interception with Burp Suite or OWASP ZAP: Configure the testing device to proxy through Burp Suite and install the Burp CA certificate. For Android 7+, user-installed CA certificates are not trusted by default for app network traffic (requires the app's network security config to allow user certificates or the device to be rooted). Bypass options:
- Use Android 6 or earlier (emulator) where user CAs are trusted
- Root the device/emulator and move the Burp certificate to the system trust store
- Patch the APK's network security configuration using apktool to remove certificate pinning or add user CA trust, then resign and install
Certificate pinning bypass: Many banking and enterprise apps implement certificate pinning. Common bypass approaches:
- Frida with the ssl-pinning-bypass script (works against common pinning implementations)
- objection framework (
objection --gadget "com.app.name" explorethenandroid sslpinning disable) - APK patching via apktool to remove pinning code
Frida for runtime analysis: Frida is a dynamic instrumentation toolkit that injects a JavaScript bridge into a running process, allowing you to hook any function, read memory, and modify return values at runtime. Key uses in mobile testing: hook authentication functions to bypass checks, intercept cryptographic operations to see plaintext, and monitor file system and network calls.
Objection wraps Frida with a mobile-specific command interface for common tasks: disabling root detection, disabling SSL pinning, listing files, extracting the keychain (iOS), and dumping SQLite databases.
Data Storage and Authentication Testing
Data storage vulnerabilities are the most commonly found mobile security issue. Systematic testing requires examining every location where the app persists data.
Android data storage locations to test:
- SharedPreferences (
/data/data/com.app.name/shared_prefs/) -- often used to store tokens and preferences; frequently unencrypted - SQLite databases (
/data/data/com.app.name/databases/) -- schema, data, and query construction - Internal storage files (
/data/data/com.app.name/files/) - External storage (
/sdcard/Android/data/com.app.name/) - Logs (
logcatoutput during authentication flows) - Clipboard (apps that write sensitive data to clipboard)
iOS data storage locations to test:
- NSUserDefaults (plist files in Library/Preferences/)
- Keychain items with incorrect accessibility settings
- CoreData SQLite databases
- Cached HTTP responses (NSURLCache)
- Application snapshots (iOS saves a screenshot when the app goes to background -- may capture sensitive UI)
Authentication testing checklist:
- Can the session token be replayed from a different device?
- Does the app implement biometric authentication for high-risk operations, or only for app unlock?
- Is the authentication token stored in a secure location (Keychain on iOS, Android Keystore-backed EncryptedSharedPreferences)?
- Does the token expire after a reasonable inactivity period?
- Can BOLA (broken object-level authorization) attacks access other users' data by changing object IDs in API requests?
- Does the app implement proper logout (invalidating server-side sessions, not just deleting the local token)?
Third-Party SDK Risk Assessment
The average consumer app contains 30+ third-party SDKs. Enterprise apps typically have 15-25. Each SDK has its own data collection practices, permissions usage, and vulnerability history -- and they run with the same permissions as the app itself.
High-risk SDK categories:
- Analytics SDKs (Firebase Analytics, Amplitude, Mixpanel): Often collect device identifiers, IP addresses, and screen content. Verify what data is transmitted and whether it includes sensitive user input.
- Advertising SDKs (Google AdMob, Meta Audience Network): Historically have been vectors for ad fraud malware. Review the SDK version and recent CVE history before accepting.
- Social login SDKs (Facebook SDK, Google Sign-In): Ensure the SDK version is current; Facebook SDK in particular has had multiple high-severity vulnerabilities related to token storage and deep link handling.
- Crash reporting SDKs (Crashlytics, Sentry, Bugsnag): May capture stack traces, local variable values, and custom breadcrumbs that include sensitive data. Review what data is logged at crash time.
SDK assessment process: Extract the list of third-party libraries from the APK (using MobSF or manually from the decompiled source). For each SDK: check the version against the NVD for known CVEs, review the SDK's privacy documentation for data collection practices, and verify that the SDK does not request permissions beyond what the app itself needs.
Supply chain risk: If a dependency is abandoned (no commits in 12+ months, no response to security issues), evaluate replacing it. Abandoned SDKs are increasingly targeted by attackers who acquire control of the package namespace or the maintainer's account.
The bottom line
Mobile application security testing requires tooling and methodology distinct from web application testing. Start every engagement with MobSF for automated static analysis -- it surfaces the obvious issues (hardcoded credentials, exported components, insecure storage) in minutes. Follow with manual traffic interception using Burp Suite with certificate pinning bypass to test the API layer. The OWASP Mobile Top 10 provides the coverage framework: insecure data storage, improper credential usage, and insecure communication account for the majority of critical findings in real-world assessments. Treat third-party SDKs as part of the application attack surface, not trusted black boxes.
Frequently asked questions
What is the difference between MAST, SAST, and DAST for mobile apps?
For mobile applications, MAST (Mobile Application Security Testing) is the umbrella term for security testing of mobile apps specifically. SAST (Static Application Security Testing) analyzes the app binary or source code without running it -- tools like MobSF in static mode, jadx, and apktool enable this. DAST (Dynamic Application Security Testing) tests the running application: intercepting API traffic with Burp Suite, runtime function hooking with Frida, and behavioral monitoring. Effective mobile security testing uses both: SAST finds hardcoded credentials, crypto errors, and manifest misconfigurations; DAST finds authentication weaknesses, insecure API calls, and data leakage at runtime.
Do I need a rooted/jailbroken device for mobile security testing?
Rooting (Android) or jailbreaking (iOS) significantly expands your testing capability but is not required for all testing types. Without root: you can decompile and statically analyze the app, intercept API traffic (with limitations from certificate pinning), and test the web APIs directly. With root: you can access the full file system to inspect data storage, bypass certificate pinning by modifying the system trust store, use Frida for runtime analysis without patching the APK, and dump Keychain items (iOS). For a thorough security assessment, use a rooted Android emulator (easier than physical rooting) for dynamic analysis. For iOS testing, use a jailbroken physical device or a debug build from the development team.
How do I test an app with certificate pinning?
The standard approach is to use Frida with an ssl-pinning-bypass script, which hooks common pinning implementations at runtime and forces them to return success regardless of the certificate presented. The objection framework wraps Frida and provides a simple command: after attaching to the target app, run 'android sslpinning disable' to bypass most pinning implementations. For apps with custom pinning implementations that resist Frida hooks, the alternative is to patch the APK: decompile with apktool, modify the pinning logic or network security configuration, recompile, and sign with a test certificate. This requires identifying the specific pinning implementation in the decompiled code.
What is the OWASP Mobile Application Security Verification Standard (MASVS)?
MASVS is the OWASP standard for mobile app security requirements, complementing the Mobile Top 10 (which describes common vulnerabilities) with a structured verification checklist. MASVS defines two verification levels: MASVS-L1 covers basic security hygiene applicable to all apps, and MASVS-L2 adds defense in depth requirements (root/jailbreak detection, anti-tampering, binary protections) relevant for high-value apps like banking and healthcare. The OWASP MASTG (Mobile Application Security Testing Guide) provides the testing procedures for verifying each MASVS requirement, making it the primary reference for structuring a mobile security assessment.
How do I assess third-party SDK security risks in a mobile app?
Extract the full SDK list from the decompiled app (MobSF lists all detected third-party libraries). For each SDK: check the version against the NVD for known CVEs, check whether the SDK is actively maintained (last commit date, response to GitHub issues), and review the SDK privacy documentation for data collection practices. Pay particular attention to analytics SDKs (which may log sensitive user data), advertising SDKs (historically a malware vector), and social login SDKs (token storage history). For enterprise apps, maintain an approved SDK list and require security review before adding new SDKs.
What data should a mobile app security assessment report include?
A mobile security assessment report should include: executive summary with risk rating; testing scope (app version, OS versions tested, testing methodology); findings organized by OWASP Mobile Top 10 category and severity (Critical, High, Medium, Low); for each finding: a description, steps to reproduce, proof-of-concept evidence (screenshot or API request/response), business impact, and remediation recommendation with code example where applicable; a coverage matrix showing which OWASP Mobile Top 10 categories were tested; and a retesting plan. Include MobSF scan output as an appendix but always supplement automated findings with manual validation -- automated tools produce false positives that reduce report credibility if included without verification.
How often should mobile apps be security tested?
At minimum: before every major release (new feature sets), after any significant architectural change (new authentication system, new payment integration, new third-party SDK), and annually for apps handling sensitive data. High-risk apps (banking, healthcare, government) benefit from continuous automated scanning (SAST on every build) plus quarterly manual assessments. Bug bounty programs are an effective complement for apps with large user bases, providing continuous coverage from diverse testing perspectives. Always retest any finding after the remediation is deployed to verify the fix is complete and does not introduce new issues.
Sources & references
Free resources
Critical CVE Reference Card 2025–2026
25 actively exploited vulnerabilities with CVSS scores, exploit status, and patch availability. Print it, pin it, share it with your SOC team.
Ransomware Incident Response Playbook
Step-by-step 24-hour IR checklist covering detection, containment, eradication, and recovery. Built for SOC teams, IR leads, and CISOs.
Get threat intel before your inbox does.
50,000+ security professionals read Decryption Digest for early warnings on zero-days, ransomware, and nation-state campaigns. Free, weekly, no spam.
Unsubscribe anytime. We never sell your data.

Founder & Cybersecurity Evangelist, Decryption Digest
Cybersecurity professional with expertise in threat intelligence, vulnerability research, and enterprise security. Covers zero-days, ransomware, and nation-state operations for 50,000+ security professionals weekly.
The Mythos Brief is free.
AI that finds 27-year-old zero-days. What it means for your security program.
