close
The Wayback Machine - https://web.archive.org/web/20200908021659/https://github.com/github/securitylab/issues/140/
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Java: Detect remote source from Android intent extra #140

Open
luchua-bc opened this issue Jun 25, 2020 · 0 comments
Open

Java: Detect remote source from Android intent extra #140

luchua-bc opened this issue Jun 25, 2020 · 0 comments
Labels

Comments

@luchua-bc
Copy link

@luchua-bc luchua-bc commented Jun 25, 2020

CVE ID(s)

List the CVE ID(s) associated with this vulnerability. GitHub will automatically link CVE IDs to the GitHub Advisory Database.

Report

Describe the vulnerability. Provide any information you think will help GitHub assess the impact your query has on the open source community.

Android uses the IPC (Inter Process Communication) mechanism for communications among difference applications and different application components. The most common system functionality for IPC is Intent. Android allows a wide range of data types to be passed as intent extras.

Exported Android components including activities, services, receivers, and providers can be invoked by other applications on the same mobile device thus expose the attack surface. Android Activities, services, and receivers can be exposed in two ways:

  • Explicitly set android:exported to true
  • Set intent filters without android:exported explicitly set to false

The second scenario is very important and issues in this category are very common in Android applications.

Also please note not all intent data passed between Android components impose security concerns - intent data passed between internal components of the same application, which cannot be controlled by attackers, shall not be treated as remote source. This helps to eliminate a large amount of false positives.

The related PR is #3812, which addresses the following two issues:

  • Enhance the Android library Android.qll and AndroidManifest.qll to handle the second scenario with intent filters
  • Implement a remote source for Android intent extra
  • Are you planning to discuss this vulnerability submission publicly? (Blog Post, social networks, etc). We would love to have you spread the word about the good work you are doing

Result(s)

Provide at least one useful result found by your query, on some revision of a real project.
As the relevant PR enhances the core library, there is no accompanying query to run against real projects. Security researchers including myself can use the new remote source of Android intent extra as entry points to detect various security vulnerabilities in real Android projects. I will submit PRs for specific CWE vulnerability types in separate reports.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.