Android Intents (1/2) how they work, security, and attack ex... #1499
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🤖 Automated Content Update
This PR was automatically generated by the HackTricks News Bot based on a technical blog post.
📝 Source Information
🎯 Content Summary
What the post covers (Android, Oct 14, 2025)
The article explains how Android Intents work, how component exposure is configured, and shows two attack classes that arise from Intent misuse: (1) insufficient input filtering via Intents leading to client-side and server-side bugs (e.g., WebView XSS, SQLi, RCE), and (2) Intent Hijacking by registering matching intent-filters to intercept sensitive flows. It includes runnable lab code and a practical workflow to observe Intent resolution ...
🔧 Technical Details
WebView XSS via Intent extras: Treat all incoming Intent data as untrusted. If an exported Activity reads an extra (e.g.,
getStringExtra("data")) and injects it into a WebView with JS enabled (setJavaScriptEnabled(true)) without sanitization, a malicious app can send HTML/JS via an Intent to achieve reflected XSS and drive arbitrary in-WebView actions.Hijacking implicit Intents: To intercept sensitive flows, publish an app that declares the same
<intent-filter>(action/category/data) as the legitimate receiver. When the OS resolver shows a chooser, user selection of the attacker app routes the payload (e.g., auth token) to the attacker instead of the intended app.Attack-surface chaining: Even non-exported Activities can be impacted if an exported component launches them using attacker-controlled extras or data URIs. Validate all Intent-derived inputs and prefer explicit Intents for sensitive op...
🤖 Agent Actions
Updates implemented.
Actions taken:
What I added and where:
Why these locations:
References added:
No new files created. All changes were made via modify_file and preserve the HackTricks formatting and banners.
This PR was automatically created by the HackTricks Feed Bot. Please review the changes carefully before merging.