diff options
author | 2025-02-07 13:44:13 -0800 | |
---|---|---|
committer | 2025-02-07 13:44:13 -0800 | |
commit | 85c368a6f422e39ac1ae4656d94429b6bd1db420 (patch) | |
tree | ec5ba4a4b7bfe12e13cf8de1f94fa2c8ab7cd5fa /telephony/java/com | |
parent | b1d4e2ef49da6ae500a677570e7e6cd8db91ffaa (diff) |
Fixed incorrect permission check
isSubscriptionAssociatedWithUser API should also allow callers
with READ_PRIVILEGED_PHONE_STATE permission to access
Bug: 394859326
Test: atest SubscriptionManagerTests
Test: Basic telephony functionality tests
Flag: EXEMPT bug fix
Change-Id: I9aa3953912d71fd2f2914361669c2ffb9bb417fd
Diffstat (limited to 'telephony/java/com')
-rw-r--r-- | telephony/java/com/android/internal/telephony/ISub.aidl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/telephony/java/com/android/internal/telephony/ISub.aidl b/telephony/java/com/android/internal/telephony/ISub.aidl index 1bfec29a3cf4..a974c615a4ae 100644 --- a/telephony/java/com/android/internal/telephony/ISub.aidl +++ b/telephony/java/com/android/internal/telephony/ISub.aidl @@ -347,13 +347,17 @@ interface ISub { * Returns whether the given subscription is associated with the calling user. * * @param subscriptionId the subscription ID of the subscription + * @param callingPackage The package maing the call + * @param callingFeatureId The feature in the package + * @return {@code true} if the subscription is associated with the user that the current process * is running in; {@code false} otherwise. * * @throws IllegalArgumentException if subscription doesn't exist. * @throws SecurityException if the caller doesn't have permissions required. */ - boolean isSubscriptionAssociatedWithCallingUser(int subscriptionId); + boolean isSubscriptionAssociatedWithCallingUser(int subscriptionId, String callingPackage, + String callingFeatureId); /** * Check if subscription and user are associated with each other. |