Abstract
Android Framework is a layer of software that exists in every Android system managing resources of all Android apps. A vulnerability in Android Framework can lead to severe hacks, such as destroying user data and leaking private information. With tens of millions of Android devices unpatched due to Android fragmentation, vulnerabilities in Android Framework certainly attract attackers to exploit them. So far, enormous manual effort is needed to craft such exploits. To our knowledge, no research has been done on automatic generation of exploits that take advantage of Android Framework vulnerabilities. We make a first step towards this goal by applying symbolic execution of Android Framework to finding bugs and generating exploits. Several challenges have been raised by the task. (1) The information of an app flows to Android Framework in multiple intricate steps, making it difficult to identify symbolic inputs. (2) Android Framework has a complex initialization phase, which exacerbates the state space explosion problem. (3) A straightforward design that builds the symbolic executor as a layer inside the Android system will not work well: not only does the implementation have to ensure the compatibility with the Android system, but it needs to be maintained whenever Android gets updated. We present novel ideas and techniques to resolve the challenges, and have built the first system for symbolic execution of Android Framework. It fundamentally changes the state of the art in exploit generation on the Android system, and has been applied to constructing new techniques for finding vulnerabilities.
Introduction
The Android Framework is a massive software layer managing resources for every application on a device. While vulnerabilities in this layer are devastating—potentially allowing attackers to steal sensitive data or hijack user interfaces—exploiting them has historically required immense manual effort. Standard automated exploit tools often fail on Android due to three primary factors: intricate information flows from apps to the framework, the "state space explosion" caused by complex framework initialization, and the maintenance burden of coupling a symbolic executor directly with the Android Runtime (ART).
The CENTAUR System
To address these challenges, we present CENTAUR, a system that automates exploit generation by combining concrete system initialization with targeted symbolic execution.
Decoupled Architecture and Hybrid Execution
Instead of symbolically executing the entire boot process, CENTAUR employs a hybrid approach. It runs the Android system normally (concrete execution) to reach a "ready" state. Once initialized, it takes a heap memory snapshot. The symbolic execution engine, based on Symbolic PathFinder, runs outside the Android system and communicates with a "context query server" to pull necessary class and object information from the snapshot as needed.
Identifying Symbolic Inputs via Slim Tainting
Identifying which variables an attacker can manipulate is difficult because data flows through many layers. CENTAUR uses "slim tainting" to mark variables as symbolic inputs "just in time." It identifies specific patterns, such as array indexing based on a User ID (UID) or hash map lookups using package names, to determine which parts of the framework's state are influenced by a malicious application.
Evaluation and Results
CENTAUR was evaluated on Android Framework 5.0, focusing on Inconsistent Security Policy Enforcement (ISPE) and Task Hijacking vulnerabilities. The system verified generated exploits across 60 different emulators to ensure cross-device reliability.
- Efficiency and Accuracy: CENTAUR generated 810 verified exploits for a task hijacking vulnerability in approximately 14.5 minutes. Crucially, the system achieved zero false positives; every reported vulnerability was validated by a working exploit.
- Discovery of Hidden Bugs: CENTAUR identified vulnerabilities that were previously thought to be patched. By providing concrete context through snapshots, it succeeded where Under-constrained Symbolic Execution (UCSE) failed due to memory exhaustion.
Conclusion and Future Work
CENTAUR represents a significant advancement in automated Android security analysis. By decoupling symbolic execution from the core system and using concrete snapshots, it bypasses traditional performance bottlenecks. Future work will focus on handling deeply nested native code (JNI) and automating the construction of final malicious payloads, such as UI overlays for spoofing attacks.
Summary updated