diff options
| author | 2015-12-04 11:51:49 -0800 | |
|---|---|---|
| committer | 2015-12-22 15:29:42 -0800 | |
| commit | a2590b5e7fb8a4a26ea530e59b2b630acc112bd9 (patch) | |
| tree | 2bae45d6a2f91746f3b83b086561b9061d20b3b1 | |
| parent | 9e4d4143cf64df95e0bf129068e323230ff15447 (diff) | |
Check permissions on getDeviceId. DO NOT MERGE
This needs the package name passed in, so the aidl changes.
bug:25778215
Change-Id: I69ee88f1d2db614bad51e6de908d3f16881a0231
| -rw-r--r-- | telephony/java/android/telephony/TelephonyManager.java | 4 | ||||
| -rw-r--r-- | telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java index 3b281e222bd8..0b5aaa3b273b 100644 --- a/telephony/java/android/telephony/TelephonyManager.java +++ b/telephony/java/android/telephony/TelephonyManager.java @@ -766,7 +766,7 @@ public class TelephonyManager { IPhoneSubInfo info = getSubscriberInfo(); if (info == null) return null; - return info.getDeviceIdForPhone(slotId); + return info.getDeviceIdForPhone(slotId, mContext.getOpPackageName()); } catch (RemoteException ex) { return null; } catch (NullPointerException ex) { @@ -4865,4 +4865,4 @@ public class TelephonyManager { } return null; } -}
\ No newline at end of file +} diff --git a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl index ed85392dd4d7..dc2b297f6dbe 100644 --- a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl +++ b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl @@ -36,7 +36,7 @@ interface IPhoneSubInfo { * Retrieves the unique device ID of a phone for the device, e.g., IMEI * for GSM phones. */ - String getDeviceIdForPhone(int phoneId); + String getDeviceIdForPhone(int phoneId, String callingPackage); /** * Retrieves the IMEI. |