Android Legacy Security
ASecurityTreat the entire incoming implicit Intent as untrusted. If the Activity is internal, make it `android:exported="false"` and use an explicit Intent instead. If it must receive a deep link or another external request, validate all of the following before performing any action: - Allow only the expected action, categories, MIME type, and data scheme/host/path. Reject unexpected or missing values; do not accept arbitrary `file://` data. - Read each extra with the expected type (`getStringExtra`, ...
- 584 stars
- 0 votes
- 0 copies
- 7 views
- Added September 5, 2026
Works with
Security analysis
100/100Pro scans all 18 files and shows the line behind each finding
npx -y skills add HoangNguyen0403/agent-skills-standard --skill android-legacy-security --agent claude-codeAre you the author of Android Legacy Security?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/hoangnguyen0403-android-legacy-security-71f7c116)Treat the entire incoming implicit Intent as untrusted. If the Activity is internal, make it `android:exported="false"` and use an explicit Intent instead. If it must receive a deep link or another external request, validate all of the following before performing any action:
- Allow only the expected action, categories, MIME type, and data scheme/host/path. Reject unexpected or missing values; do not accept arbitrary `file://` data.
- Read each extra with the expected type (`getStringExtra`, `getIntExtra`, or a typed Parcelable API), then validate format, length, range, and allowed values. Treat null, malformed, oversized, duplicate, or unexpected extras as invalid. Do not blindly deserialize untrusted `Serializable` or `Parcelable` data.
- Do not use an extra such as `user_id`, role, path, or “is_admin” as proof of identity or authorization. Re-check authorization against the authenticated account and server-side state. If only a trusted caller may invoke the component, enforce a platform signature-level permission or another authenticated caller mechanism; do not trust a package name supplied in an extra.
- If the Intent carries a URI or stream, require the expected `content://` provider and validate the authority and resource before reading it. Use only the temporary grant needed for that resource.
For a sensitive operation, reject the request on any failed check, log only safe diagnostic metadata, and avoid launching another implicit Intent with unvalidated values. For outgoing implicit Intents, separately verify `resolveActivity(packageManager)` before starting them; that check does not make incoming Intent data trustworthy.
Files in this skill
- eval-1.baseline.md
- eval-1.with-skill.md
- eval-2.baseline.md
- eval-2.with-skill.md
- eval-3.baseline.md
- eval-3.with-skill.md
- trigger-1.md
- trigger-10.md
- trigger-11.md
- trigger-2.md
- trigger-3.md
- trigger-4.md
- trigger-5.md
- trigger-6.md
- trigger-7.md
- trigger-8.md
- trigger-9.md
Attribution
Related skills
View all in development →Comments
Loading comments…
Newsletter
Get the weekly list of safe new skills, and the ones we pulled.