summaryrefslogtreecommitdiffstats
path: root/telephony
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2009-07-09 18:14:31 -0700
committerDianne Hackborn <hackbod@google.com>2009-07-09 18:14:31 -0700
commit854060af30f928c0a65591e9c8314ae17056e6b8 (patch)
tree90922c34cec925074bb62a3b79ac65af5527c02a /telephony
parentd1e5e3ffc22478bad8525dec4f1c6d57fe0ad368 (diff)
downloadframeworks_base-854060af30f928c0a65591e9c8314ae17056e6b8.zip
frameworks_base-854060af30f928c0a65591e9c8314ae17056e6b8.tar.gz
frameworks_base-854060af30f928c0a65591e9c8314ae17056e6b8.tar.bz2
Fix bug #1873249i: Apps can DoS/brick device
This is the problem where various things are listening for broadcasts (such as battery status, PIN/PUK/Network) that an application can send to cause harm to the system. Solving this is tricky because many of these broadcasts are sticky, and I have never figured out how to do permissions with sticky broadcasts in a sane way. So instead, I am going to punt on the general problem and just brute force it: There is new a way for system components to declare specific broadcast actions to be protected, which means that only the system and the phone can send them. This is good enough for now. None of it is exposed in the public API so we can make something a little less stupid in the future if we ever need to.
Diffstat (limited to 'telephony')
-rw-r--r--telephony/java/com/android/internal/telephony/TelephonyIntents.java33
1 files changed, 33 insertions, 0 deletions
diff --git a/telephony/java/com/android/internal/telephony/TelephonyIntents.java b/telephony/java/com/android/internal/telephony/TelephonyIntents.java
index 9152211..02e9800 100644
--- a/telephony/java/com/android/internal/telephony/TelephonyIntents.java
+++ b/telephony/java/com/android/internal/telephony/TelephonyIntents.java
@@ -32,6 +32,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_SERVICE_STATE_CHANGED = "android.intent.action.SERVICE_STATE";
@@ -50,6 +53,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires no permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_RADIO_TECHNOLOGY_CHANGED
= "android.intent.action.RADIO_TECHNOLOGY";
@@ -66,6 +72,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires no permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_EMERGENCY_CALLBACK_MODE_CHANGED
= "android.intent.action.EMERGENCY_CALLBACK_MODE_CHANGED";
@@ -89,6 +98,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_SIGNAL_STRENGTH_CHANGED = "android.intent.action.SIG_STR";
@@ -110,6 +122,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_ANY_DATA_CONNECTION_STATE_CHANGED
= "android.intent.action.ANY_DATA_STATE";
@@ -127,6 +142,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_DATA_CONNECTION_FAILED
= "android.intent.action.DATA_CONNECTION_FAILED";
@@ -148,6 +166,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_SIM_STATE_CHANGED
= "android.intent.action.SIM_STATE_CHANGED";
@@ -163,6 +184,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_NETWORK_SET_TIME = "android.intent.action.NETWORK_SET_TIME";
@@ -178,6 +202,9 @@ public class TelephonyIntents {
*
* <p class="note">
* Requires the READ_PHONE_STATE permission.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_NETWORK_SET_TIMEZONE
= "android.intent.action.NETWORK_SET_TIMEZONE";
@@ -187,6 +214,9 @@ public class TelephonyIntents {
* <p class="note">.
* This is to pop up a notice to show user that the phone is in emergency callback mode
* and atacalls and outgoing sms are blocked.
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*/
public static final String ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS
= "android.intent.action.ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS";
@@ -197,6 +227,9 @@ public class TelephonyIntents {
* <ul>
* <li><em>mdn</em> - An Integer of the updated MDN number.</li>
* </ul>
+ *
+ * <p class="note">This is a protected intent that can only be sent
+ * by the system.
*
* <p class="note">
*/