1842
Applicable Platforms
Language : Not Language-Specific (Prevalence = Undetermined)
Technology : Mobile (Prevalence = Undetermined)
Alternate Terms
Intent Spoofing :
Common Consequences
Scope Impact Likelihood
Integrity Gain Privileges or Assume Identity
Another application can impersonate the operating system
and cause the software to perform an unintended action.
Detection Methods
Automated Static Analysis
Automated static analysis, commonly referred to as Static Application Security Testing (SAST),
can find some instances of this weakness by analyzing source code (or binary/compiled code)
without having to execute it. Typically, this is done by building a model of data flow and control
flow, then searching for potentially-vulnerable patterns that connect "sources" (origins of input)
with "sinks" (destinations where the data interacts with external components, a lower layer such
as the OS, etc.)
Effectiveness = High
Potential Mitigations
Phase: Architecture and Design
Before acting on the Intent, check the Intent Action to make sure it matches the expected System
action.
Demonstrative Examples
Example 1:
The following example demonstrates the weakness.
Example Language: XML (Bad)
<manifest package="com.example.vulnerableApplication">
<application>
...
<receiver android:name=".ShutdownReceiver">
<intent-filter>
<action android:name="android.intent.action.ACTION_SHUTDOWN" />
</intent-filter>
</receiver>
...
</application>
</manifest>
The ShutdownReceiver class will handle the intent:
Example Language: Java (Bad)
...
IntentFilter filter = new IntentFilter(Intent.ACTION_SHUTDOWN);
BroadcastReceiver sReceiver = new ShutDownReceiver();
CWE Version 4.14
CWE-926: Improper Export of Android Application Components
CWE-926: Improper Export of Android Application Components