Mobile app penetration testing: OWASP MASVS, MASTG and common findings
In short: Mobile app penetration tests check how Android and iOS apps store data, communicate, authenticate and use the platform, and test the backend APIs behind them. The OWASP MASVS sets the security requirements and the MASTG explains how to test them. Common findings include sensitive data stored on the device, hard-coded keys and weak server-side access checks.
Why mobile apps need their own test
A mobile app is two things: the code running on the phone, and the backend APIs it talks to. Attackers can download any public app, unpack it and study it at leisure, so nothing in the app itself can be fully trusted. A mobile test checks both halves. Web-style flaws in the backend are covered in API security and web application testing.
OWASP MASVS and MASTG
The OWASP Mobile Application Security Verification Standard (MASVS) lists what a secure mobile app should do, grouped into areas such as storage, cryptography, authentication, network, platform interaction, code quality and resilience. The Mobile Application Security Testing Guide (MASTG) explains how testers check each requirement on Android and iOS. Together they give clients and testers a shared checklist, much like the methodologies used for other tests.
Static and dynamic testing
Testers usually work on dedicated test devices or emulators, and route the app's traffic through an intercepting proxy to see and change requests. Some apps use certificate pinning to stop this; in an authorised test, the client may provide a test build without pinning so the testing time is spent on real issues.
Common findings
| Finding | Fix |
|---|---|
| Tokens or personal data stored in plain files or logs | Use the Android Keystore or iOS Keychain; avoid logging sensitive data |
| API keys or secrets hard-coded in the app | Keep secrets on the server; assume anything in the app is public |
| Backend trusts the app to enforce rules | Check every permission on the server for every request |
| Weak session handling | Short-lived tokens, server-side logout, secure refresh |
| Unsafe deep links or exported components | Validate all input from links and other apps |
Real-world example: a fitness app's hidden admin key
A fictional fitness start-up asks for a test before launching its Android and iOS apps. Unpacking the Android app, the tester finds an API key for the company's cloud storage hard-coded in the code, with permission to list all users' progress photos. Dynamic testing also shows the backend returns another user's profile if the user ID in a request is changed. The start-up moves storage access behind its own API with per-user checks, removes the key, rotates it and adds server-side authorisation to every endpoint. The launch goes ahead two weeks later after a successful retest.
Practice
What are the two halves a mobile app test must cover?
What is the difference between MASVS and MASTG?
Why should secrets never be hard-coded in a mobile app?
Key takeaways
- Mobile tests cover the app on the device and its backend APIs.
- OWASP MASVS sets requirements; MASTG explains how to test them.
- Testers combine static analysis with dynamic testing through a proxy.
- Insecure storage, hard-coded secrets and weak server checks are common findings.
- Assume everything in the app is public and enforce rules on the server.
Original content written by Mohamed Fayas for FM TecHub. © 2026 FM TecHub. You're welcome to share a link to this page; please don't copy the text elsewhere without permission.