From a8366aeae40143a3d706de43772d4c7cde59b513 Mon Sep 17 00:00:00 2001 From: Brad Ebinger Date: Tue, 23 Mar 2021 21:01:51 +0000 Subject: Enforce READ_PHONE_STATE for APIs involving call state For API version 31+, ensure that READ_PHONE_STATE is checked on APIs that retrieve/notify the call state of the device. Bug: 157233955 Test: atest CtsTelecomTestCases2 CtsTelephony2TestCases Change-Id: I9f8674a3075d3e0f75ee4f41eefce328c0fa6b91 --- telecomm/java/com/android/internal/telecom/ITelecomService.aidl | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'telecomm/java/com') diff --git a/telecomm/java/com/android/internal/telecom/ITelecomService.aidl b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl index 78283fa73514..18afde742abb 100644 --- a/telecomm/java/com/android/internal/telecom/ITelecomService.aidl +++ b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl @@ -195,10 +195,17 @@ interface ITelecomService { /** * @see TelecomServiceImpl#getCallState + * Note: only kept around to not break app compat, however this will throw a SecurityException + * on API 31+. */ @UnsupportedAppUsage(maxTargetSdk = 30, trackingBug = 170729553) int getCallState(); + /** + * @see TelecomServiceImpl#getCallState + */ + int getCallStateUsingPackage(String callingPackage, String callingFeatureId); + /** * @see TelecomServiceImpl#endCall */ -- cgit v1.2.3-59-g8ed1b