Lesson 1 of 4 · 17 min · Intermediate

Setting up a mobile testing lab

Emulators, rooted devices and interception proxies.

In this lesson you will

  • Explain what a mobile application assessment covers and how it maps to OWASP MASVS
  • Scope a mobile engagement and gather what you need from the client
  • Build an Android lab with an emulator, adb and an interception proxy
  • Understand the options and limits for testing iOS apps

A mobile app is really three things: the app package on the device, the device and operating system it runs on, and the back-end APIs it talks to. A mobile assessment tests all three. This track follows the industry standard for that work, from OWASP.

Authorised testing only. Test your own apps, deliberately vulnerable training apps, or client apps you have written permission to assess. Store terms and the law in most countries prohibit reverse engineering other people's apps without permission.

OWASP MASVS and MASTG

  • The Mobile Application Security Verification Standard (MASVS) defines what a secure app must do.
  • The Mobile Application Security Testing Guide (MASTG) explains how to test each requirement, with techniques and tools for Android and iOS.
  • The MAS Checklist links the two, and is what many testers use to track coverage.

MASVS v2 groups requirements into eight control groups:

Group What it covers
MASVS-STORAGE Sensitive data stored on the device, logs, backups
MASVS-CRYPTO Correct use of cryptography and key management
MASVS-AUTH Authentication and authorisation, local and remote
MASVS-NETWORK Secure communication: TLS, certificate validation, pinning
MASVS-PLATFORM Interaction with the OS and other apps: IPC, deep links, WebViews
MASVS-CODE Dependencies, input validation, platform updates
MASVS-RESILIENCE Resistance to tampering and reverse engineering
MASVS-PRIVACY Data minimisation, transparency and user control

Map every finding in your report to a MASVS control. Clients, especially banks and fintechs following regulator guidance, increasingly ask for exactly that.

What a mobile assessment includes

Activity Examples
Static analysis Decompiling the app, reviewing the manifest or Info.plist, finding hard-coded secrets and risky APIs
Dynamic analysis Running the app, watching files, logs and memory, testing IPC and deep links
Traffic analysis Intercepting app-to-server traffic and checking TLS and certificate validation
Back-end API testing Testing the APIs the app uses for authorisation and logic flaws (see the API Security Testing track)
Resilience review Root/jailbreak detection, obfuscation and tamper checks, when in scope

In practice, the most serious findings usually come from the back-end API, because the app is only a client and every API call it makes can be replayed and modified.

Scoping a mobile engagement

Ask the client for:

  1. Builds: the APK or AAB for Android, and an IPA or TestFlight access for iOS. A debug or non-production build often speeds testing; confirm whether the release build must also be checked.
  2. Test accounts for each role, with test data in a non-production environment.
  3. API documentation and the back-end hosts in scope.
  4. Which protections to expect: certificate pinning, root detection, obfuscation. Ask whether they can provide a build with pinning disabled for testing, which saves time and keeps the focus on real flaws.
  5. Platforms and minimum OS versions the app supports.
  6. Special concerns: payments, health data, biometrics, offline features.

Building an Android lab

Emulator or physical device?

Option Pros Cons
Android Studio emulator (Google APIs image, not Play Store) Free, easy root access via adb root, snapshots Some apps detect emulators; ARM-only libraries can be slow
Genymotion Fast, convenient Licence needed for commercial use
Dedicated physical test device Most realistic; needed for some hardware features Rooting takes effort; never use your personal phone

Use a dedicated test device or emulator that holds no personal accounts or data.

Core tools

Tool Purpose
adb (Android Debug Bridge) Install apps, open a shell, read logs, copy files
jadx Decompile APKs to readable Java/Kotlin-like code
apktool Decode resources and the manifest; rebuild apps
MobSF (Mobile Security Framework) Automated static and dynamic analysis reports
Burp Suite or OWASP ZAP Intercept and modify HTTPS traffic
Frida and objection Runtime instrumentation, for authorised dynamic testing
bash
# Basic adb workflow against an emulator
adb devices
adb install app-debug.apk
adb shell pm list packages | grep example
adb logcat | grep -i example

Practice apps

Deliberately vulnerable apps let you practise every technique legally:

  • OWASP MAS Crackmes and the MASTG demo apps
  • InsecureBankv2, DIVA (Damn Insecure and Vulnerable App), AndroGoat, InjuredAndroid
  • DVIA-v2 for iOS

iOS testing options

iOS is more locked down, which changes how you test:

  • A jailbroken test device gives the deepest access (file system, runtime instrumentation). Jailbreaks exist only for certain device and iOS version combinations, so test teams keep older devices for this purpose.
  • Without a jailbreak you can still intercept traffic, test the back end, analyse the IPA statically, and, with a development-signed build from the client, use some instrumentation tools.
  • macOS with Xcode is needed for many tasks, such as viewing device logs and installing development builds.
  • The Simulator runs apps compiled for it, which is useful only when the client provides a simulator build.

Setting up interception

Every mobile test needs traffic interception. On an Android emulator:

  1. Start Burp Suite with a listener on all interfaces (for example port 8080).
  2. Set the emulator's proxy to your host's IP and that port (Extended controls → Settings → Proxy, or Wi-Fi settings on a device).
  3. Export Burp's CA certificate.
  4. Install the certificate. Since Android 7, apps ignore user-installed CAs by default. For your own debug builds, add a network_security_config that trusts user CAs in debug only. On a rooted test emulator, the certificate can be installed in the system store instead.

You'll go deeper into traffic testing, including certificate pinning, in lesson 3.

Lab

  1. Install Android Studio, create an emulator with a Google APIs system image, and confirm adb devices sees it.
  2. Install jadx, apktool, MobSF (Docker is easiest) and Burp Suite Community.
  3. Install InsecureBankv2 or AndroGoat on the emulator and set up Burp interception.
  4. Download the MAS Checklist and create a spreadsheet you'll fill in as you test through this track.

Checkpoint

  1. What's the difference between MASVS and MASTG?
  2. Why do the most serious mobile findings often come from the back-end API?
  3. Why should you never use your personal phone for testing?
  4. Why don't Android 7+ apps trust a user-installed proxy certificate by default?
  5. Name four things to request from the client when scoping.