Post

Audit report of a vulnerable Android application

Static and dynamic analysis of an Android application following the OWASP methodology, with a technical and executive report, CVSS scoring and mitigation recommendations.

Audit report of a vulnerable Android application

Introduction

We carry our bank account, our private conversations, our photos and even our house keys in our pocket. It all fits into a handful of apps installed on our phone. But have you ever wondered what goes on inside those apps? Where do they store your passwords? Does your data travel encrypted or in plain text? Could someone with your phone in their hand, or simply connected to the same Wi-Fi network, access information they shouldn’t?

Answering those questions is exactly the job of a mobile application pentester: putting yourself in an attacker’s shoes, but with permission and a clear goal, finding the flaws before someone with worse intentions does.

In this post I present a security audit report carried out on a deliberately vulnerable Android application. The idea is to simulate a real engagement from start to finish: from the moment the APK lands in my hands until a document is delivered that both a business manager and a development team can understand and, above all, use to fix the problems.

A pentest doesn’t end when a vulnerability is found, but when it is explained in a way that someone can fix it. The report is the real deliverable.

Project objectives

The main objective is to identify, document and assess the security vulnerabilities of an Android application, reproducing the process and format of a professional audit. Specifically:

  • Follow a recognized methodology, OWASP’s for mobile device security, so that the analysis is systematic and repeatable, and not a mere collection of isolated tests.
  • Analyze the application statically and dynamically to detect weaknesses both in its code and in its runtime behavior.
  • Assign a CVSS score to each vulnerability to measure its severity objectively and prioritize its remediation.
  • Propose concrete security recommendations to mitigate or eliminate each of the flaws.
  • Produce a technical and executive report detailing the vulnerabilities found and the results of the audit.

Context: how do you audit an Android app?

Before getting into the report, it is worth clarifying some key concepts.

Static analysis and dynamic analysis

A mobile app audit relies on two complementary approaches:

  • Static analysis: consists of examining the application without running it. An Android app is distributed as an APK file, which is essentially a compressed package containing the application’s code, resources and configuration. By decompiling it we can review its code, its AndroidManifest.xml file (where permissions and components are declared) and look for typical mistakes such as keys or credentials hardcoded in the code, exposed components or insecure configurations. It’s like reviewing a building’s blueprints looking for doors that shouldn’t be there.
  • Dynamic analysis: consists of observing the application while it runs on a device or emulator. Here we study how it behaves in practice: what data it stores, what information it sends over the network, how it reacts to manipulated inputs or whether its controls can be bypassed. Continuing with the metaphor, we no longer look at the blueprints: we walk through the building and try to open those doors.

Neither approach is sufficient on its own. Static analysis points out suspicions; dynamic analysis confirms (or rules them out) and demonstrates their real impact.

The OWASP methodology for mobile

OWASP (Open Worldwide Application Security Project) is a leading open community in application security. For the mobile field it offers two resources that act as the “roadmap” of any serious audit:

  • OWASP MASVS (Mobile Application Security Verification Standard): defines what security requirements a mobile application must meet, grouped into areas such as data storage, cryptography, authentication, network communications, platform interaction, code quality or resilience against reverse engineering.
  • OWASP MASTG (Mobile Application Security Testing Guide): explains how to verify each of those requirements, with concrete techniques and tests.

Following this methodology ensures that the analysis covers the critical areas and that the results are comparable with those of any other professional audit.

CVSS: grading severity

Not all vulnerabilities are equal. It’s not the same for an app to show debugging information in the logs as to allow anyone to access another user’s data. To measure this objectively, CVSS (Common Vulnerability Scoring System) is used, a standard that assigns each vulnerability a score from 0 to 10 based on factors such as how easy it is to exploit, whether it requires privileges or user interaction and what impact it has on the confidentiality, integrity and availability of the information.

This score translates into a severity level (low, medium, high or critical) and is key for the organization to know what to fix first.

The report structure

The report you will find below follows the format of a real deliverable and includes:

  1. Executive summary: an overview of the results in non-technical language, aimed at management and business owners.
  2. Explanation of the vulnerabilities: what each flaw consists of and why it poses a risk.
  3. Evidence: the proof that the vulnerability exists and is exploitable.
  4. CVSS score: the severity rating of each finding.
  5. Mitigation recommendations: the concrete measures to fix each problem.

The audited application is deliberately vulnerable and is designed for educational purposes. All tests were carried out in a controlled environment. Performing this type of analysis on applications or systems without express authorization is illegal.

Audit report

Below you can read the complete final report after the audit was carried out.

This post is licensed under CC BY-NC-SA 4.0 by the author.