Analyzing Android Browser Apps for file: // Vulnerabilities

Daoyuan Wu, Rocky K. C. Chang

TL;DR

This paper reveals a widespread vulnerability, dubbed "FileCross," in Android browser apps that allows malicious apps to steal sensitive user data like cookies and browsing history. The authors developed an automated system to test 115 browsers, finding that over half are vulnerable, including popular ones like Firefox and Baidu.

What Problem Does This Paper Address?

Mobile browsers, while convenient, present a security challenge. Unlike desktop browsers, Android apps have their own private file zones, which are supposed to be inaccessible to other apps. However, the file:// protocol, when used by browsers without proper access controls, can bypass these security boundaries. This is exacerbated by Android's ability to allow external browsing requests from other apps. The authors address the critical question of how prevalent and exploitable these file:// vulnerabilities are in the Android browser ecosystem, and what types of sensitive data can be compromised.

Methods

The core of this research is an automated testing system designed to mimic real-world attacks. This system comprises three main components:

  • Commander: Runs on a PC, controlling the entire testing process via ADB.
  • Attack Executer: An Android app installed on test devices that launches the FileCross attacks.
  • Web Receiver: A server-side component that receives stolen files and validates attack success.

The system first identifies exposed browsing interfaces (EBIs) using a lightweight scoring mechanism. It then "warms up" the browser by making normal browsing requests to generate private files (like cookies). Finally, it launches four specific FileCross attack patterns (A1-A4) to steal sensitive files. The system also analyzes patches provided by developers.

Datasets

The study evaluated 115 Android browser apps collected from Google Play. The dataset was curated by filtering out outdated or withdrawn apps. The experiments were conducted on three physical Android phones (Sony Xperia J, Google Nexus 4, and Nexus 5) running Android 4.0, 4.3, and 4.4, respectively, to account for OS version differences.

Key Insights and Ideas

  • FileCross is Widespread: The file:// protocol is a significant security risk in Android browsers, with over half of the tested apps exhibiting vulnerabilities.
  • Popular Browsers are Not Immune: Major browsers like Firefox, Baidu, and Maxthon were found to be vulnerable, indicating that even well-known applications can harbor serious security flaws.
  • Unintentional Exposure is a Problem: A notable percentage of browsers expose their interfaces unintentionally, which can lead to vulnerabilities even if the developers didn't intend for them to be accessible externally.
  • Patches Aren't Always Perfect: While many developers responded positively to vulnerability reports and issued patches, one patch was found to be ineffective due to a missed attack vector, highlighting the need for robust automated testing even for fixes.
  • Engine Matters, But Implementation is Key: While some browser engines have inherent flaws, the specific implementation by browser developers is crucial for mitigating or introducing vulnerabilities.

Key Results

  • 64 out of 115 (55.7%) Android browser apps were found to be vulnerable to FileCross attacks.
  • On average, vulnerable browsers had 2.77 FileCross issues.
  • 13 out of 26 popular browsers (with over 1 million installs) were vulnerable.
  • Attack A1 (auto-download to SD card) was found in one browser, but 71 browsers were susceptible to displaying their private file contents.
  • Attacks A2, A3, and A4, which exploit Same-Origin Policy (SOP) bypasses, affected around 60 browsers each.
  • 23% of browsers exposed their browsing interfaces unintentionally, with eight of these being vulnerable.
  • 65% of browsers accepted external file:// browsing requests, and 62% allowed file:// access to private file zones.
  • 19 developers responded to vulnerability reports, with 15 confirming the issues.

Limitations and Future Work

  • False Negatives: The authors acknowledge that dynamic testing might incur false negatives due to potential instability. They mitigated this by taking the union of results from multiple test runs.
  • Pre-installed Browsers: The study did not cover pre-installed default browsers due to the difficulty of obtaining enough devices.
  • Splash/Welcome Screens: Some browsers have splash or welcome views that might interfere with automatic attacks, though the authors found this didn't always affect the underlying component's effectiveness.
  • Future Work: The authors suggest extending their system to detect similar vulnerabilities in other apps that use web engine APIs (not just browsers). They also plan to incorporate static analysis techniques to identify "similar" browsing interfaces that might not have clear EBI patterns.

Summary updated

BibTeX
@inproceedings{wu2014analyzing,
  author = {Daoyuan Wu and Rocky K. C. Chang},
  title = {{Analyzing Android Browser Apps for file: // Vulnerabilities}},
  booktitle = {Isc},
  year = {2014},
  doi = {10.1007/978-3-319-13257-0\_20},
}
Figure