summaryrefslogtreecommitdiffstats
path: root/src/com/android/server/telecom/TelecomServiceImpl.java
Commit message (Collapse)AuthorAgeFilesLines
* Telecom: refresh missed call notification on locale changeRoman Birg2016-04-221-0/+18
| | | | | | | Ticket: OPO-610 Change-Id: If31bd443671de373ebb80a11bd583be0e590b48a Signed-off-by: Roman Birg <roman@cyngn.com>
* Merge tag 'android-6.0.1_r24' into HEADJessica Wagantall2016-04-051-0/+18
|\ | | | | | | | | Ticket: CYNGNOS-2213 Android 6.0.1 release 24
| * DO NOT MERGE Check PAH in addNewIncomingCallBrad Ebinger2016-03-011-0/+18
| | | | | | | | | | | | | | | | | | Check to be sure that the PhoneAccountHandle in addNewIncomingCall corresponds to an existing registered PhoneAccount in Telecom and that the PhoneAccount is enabled. Otherwise, throw a SecurityException. Bug: 26864502 Change-Id: I6bbd8a1ece821b62bee2c94decde87a41afbf8b0
* | Merge tag 'android-6.0.1_r22' of ↵staging/cm-13.0+r22Steve Kondik2016-03-111-1/+14
|\| | | | | | | | | | | | | | | https://android.googlesource.com/platform/packages/services/Telecomm into cm-13.0 Android 6.0.1 release 22 Change-Id: I371815d38796af318dcea1e7c6cfb902a1bd0c04
| * Fix log message for phone-account unregistration.Bryce Lee2015-10-281-2/+2
| | | | | | | | Change-Id: Ib0fa08883e06057080976bc596b437e4bc6a31f8
| * Broadcast when a phone account is unregistered.Bryce Lee2015-10-281-1/+14
| | | | | | | | | | | | | | The action was previously added but not wired up. Bug: 25331205 Change-Id: If7b8910928a579c7f86a3bd42f725d4d16dec973
* | Merge tag 'android-6.0.1_r3' into cm-13.0Ethan Chen2015-12-071-1/+1
|\| | | | | | | | | | | Android 6.0.1 release 3 Change-Id: I17e539ab0604ca0bfbfbf47115e50afed253c36b
| * DO NOT MERGE Fix getAllPhoneAccounts() api methodTyler Gunn2015-10-161-1/+1
| | | | | | | | | | | | | | | | | | The getAllPhoneAccounts() API method was returning an empty list because it was it was not being filled with actual accounts from the telecom registry. Bug: 23023110 Change-Id: Ia9dc0067dc481c401c5af88011450469580d5682
| * Enforce CALL_PHONE permission for default/system dialer for non emergency callsYorke Lee2015-08-291-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | This CL fixes a bug where a default/system dialer targeting SDK 23 would be allowed to place phone calls without the CALL_PHONE permission. This is because for the default/system dialer, the Telecom system was only enforcing the CALL_PHONE app_op. In order to enforce runtime permissions for both SDK 23 and pre SDK 23 apps, both OP_CALL_PHONE and CALL_PHONE permission must be checked. Bug: 23607431 Change-Id: I57b6388349e0637df02799c14a2850c2c6e5a300
* | Telecom : Ensure null is returned for no dialer packageDanesh M2015-11-061-1/+6
| | | | | | | | | | | | Avoid npe for devices that don't have dialer package installed. Change-Id: I8e0a4e325842005bb3e1912d5dd3a9ad3b8a6353
* | Telecomm : Allow multiple default dialersDanesh M2015-11-051-5/+2
| | | | | | | | Change-Id: Ied3fe36cf5249b9ab5a9f4bdd36f2ba6e76c538e
* | MSIM: Add support for DSDA.Sandeep Kunta2015-10-061-0/+24
| | | | | | | | | | | | | | | | | | | | | | Add support for below. 1) Maintain LCH & Active subscriptions and inform changes to lower layers. 2) LCHR and SCH tones 3) Allow calls on other sub, when call is already active in the current sub. Change-Id: Id6c774496266afbda61c0ab10610221fab3daa47
* | Enforce CALL_PHONE permission for default/system dialer for non emergency callsYorke Lee2015-08-311-1/+11
|/ | | | | | | | | | | | | This CL fixes a bug where a default/system dialer targeting SDK 23 would be allowed to place phone calls without the CALL_PHONE permission. This is because for the default/system dialer, the Telecom system was only enforcing the CALL_PHONE app_op. In order to enforce runtime permissions for both SDK 23 and pre SDK 23 apps, both OP_CALL_PHONE and CALL_PHONE permission must be checked. Bug: 23607431 Change-Id: I57b6388349e0637df02799c14a2850c2c6e5a300
* Add OrSelf to privileged permission check.Amit Mahajan2015-07-301-2/+3
| | | | | Bug: 22857263 Change-Id: Ide7105dfd653e3c271330822fb8cee7cf620e35d
* Add user ID parameter for getSimCallMangaerSailesh Nepal2015-07-281-1/+13
| | | | | | | | | | The sim call manager depends on the default dialer which is a per user setting. This CL adds a user ID to the getSimCallManager API. BUG: 22790160 Change-Id: Icaf1db6c6943b3ddbd16a946a81d1bfb734d761f
* Fixed typo (READ_PHONE_STATE to READ_PRIVILEGED_PHONE_STATE)Amit Mahajan2015-07-141-1/+1
| | | | | Bug: 22468536 Change-Id: Ifaff7e62f97ae14a0695c5de3bfe9394b6099505
* Add checks for READ_PRIVILEGED_PHONE_STATE.Amit Mahajan2015-07-141-5/+12
| | | | | | | Callers will have either PRIVILEGED or regular READ_PHONE_STATE. Bug: 22468536 Change-Id: I60251f61250a975f4147b027d2539824a728e3b5
* Fix SecurityException when adding new incoming callYorke Lee2015-06-271-2/+8
| | | | | | | | | When checking to see if the caller is the SIM Manager (which now checks for the default dialer package), make sure to run the code in Telecom's UID. Bug: 22047159 Change-Id: Ie460d4cf78308def706a2c8f658451cf649e19c4
* Disallow non-emergency outgoing calls without CALL_PHONE permissionYorke Lee2015-06-231-1/+4
| | | | | Bug: 21925398 Change-Id: I9cef6cd2c11f767740d03ebce99b8b54efd1f68a
* Change Sim Call Managers to use default dialer app instead.Santos Cordon2015-06-181-36/+11
| | | | | Bug: 21499476 Change-Id: I60505ac1699f287656434b55d81aa61d4ae4ce14
* Merge "Send broadcast when default dialer changes" into mnc-devYorke Lee2015-06-151-1/+12
|\
| * Send broadcast when default dialer changesYorke Lee2015-06-151-1/+12
| | | | | | | | | | Bug: 21846308 Change-Id: I9034051644c9351bc73946fe3f5aa64bf080f200
* | Merge "Remove some dead code in TelecomServiceImpl" into mnc-devSailesh Nepal2015-06-151-10/+0
|\ \ | |/ |/|
| * Remove some dead code in TelecomServiceImplSailesh Nepal2015-06-141-10/+0
| | | | | | | | Change-Id: I151356d1ff68abb164b85de7f24d2145be17b7ed
* | Allow PSTN phone account for incoming calls from connection managerSailesh Nepal2015-06-141-6/+11
|/ | | | | | | | See ag/648273 for the original change. It looks like this was partially reverted by the refactoring for. BUG: 19591608 Change-Id: I1e95cbeff2f1813999501b1acbb2553c095638e2
* Fail PhoneAccount addition if device is not voice capable.Roshan Pius2015-06-111-0/+5
| | | | | BUG: 20305650 Change-Id: Id0702fc96e8e70be868fd8bb72252b81e7f1589e
* Reduce log level for "not visible for calling user" logs.Roshan Pius2015-06-091-7/+7
| | | | | Bug: 19589413 Change-Id: I2ddaa3fd8211e209d68567fa85f3656d21a08e47
* Remove permission checks for registerPhoneAccountYorke Lee2015-06-041-6/+0
| | | | | | | | Remove permissions required to register call provider and connection manager. Bug: 20303674 Change-Id: I14a16a2eadc4f74b41715dcf32e5b57aeb88e63a
* Add ringer logging to telecom.Santos Cordon2015-06-031-0/+1
| | | | | Bug: 21595219 Change-Id: I51ccaf4db1bd5d6238fa8f7e7091d092b75d0c1a
* Allow default dialer changes and phone account enable/disable via ADBYorke Lee2015-06-021-2/+17
| | | | | | | | | | | | | | | | | Add commands accessible via adb shell that can be used for CTS tests without the need for adb root *set-phone-account-enabled *set-phone-account-disabled *set-default-dialer *get-default-dialer Modify enablePhoneAccount/setDefaultDialer to indicate success. Remove now unused functionality in ProtectedEnableAccountPreferenceActivity and ProtectedChangeDefaultDialerActivity. Bug: 21583012 Change-Id: I542d145cc969334c004b8344fbbb01f278256f9d
* Protecting PII data.Santos Cordon2015-05-221-7/+7
| | | | | Bug: 21204385 Change-Id: I95a82e6ae79b728ed75da25be3beedd0e66d5b41
* Merge "Provide enable property on phone accounts." into mnc-devSantos Cordon2015-05-191-3/+22
|\
| * Provide enable property on phone accounts.Santos Cordon2015-05-191-3/+22
| | | | | | | | | | Bug: 20303449 Change-Id: I4b9cb0e29377233ed4fc01757570351ee6e5856e
* | Privileged dialers always have phone-related runtime permissionsYorke Lee2015-05-181-9/+20
| | | | | | | | | | Bug: 20266292 Change-Id: If4492d9cdc7806167b9b586764b11187235cfd3a
* | TelecomServiceImpl permissions cleanupYorke Lee2015-05-181-21/+25
|/ | | | | | | | | Simplify some code that does permission checks Allow default dialer to use placeCall API. Bug: 20266292 Change-Id: Ib31ae5f7debb41df9daa5dce330a7a86ac58e81a
* Add a slew of clearCallingIdentity() invocations to telecom.Santos Cordon2015-05-151-13/+62
| | | | | | | | | | | | | | We used to use Handlers to move things onto the telecom main thread when they came in through Binder calls. This also had the effect of switching to telecom's calling identity. Since we no longer do that, we need to manually reset the calling identity to avoid the permissions failures that we've been seeing lately. This change adds all the checks that are necessary today and checks which would help down the road if any code changes. Bug: 20830275 Change-Id: I73e3e2d310a505ac96abe3aed7f2118346c7be1f
* Fix crash caused by incorrect permission in TelecomServiceImpl.Sharvil Nanavati2015-05-141-11/+23
| | | | | | | | | | Without this change, the addNewIncomingCall and addNewUnknownCall would use the caller's permissions instead of Telecom's permissions. The caller may not have android.permission.BIND_CONNECTION_SERVICE resulting in the process crashing. Bug: 21057492 Change-Id: Ia67d1e32914c814cdff1af987eb72ed1aa759bdb
* Clean up PhoneAccountRegistrar.Santos Cordon2015-05-111-6/+5
| | | | | | | | | | | | Cleanup lots of duplicate code and consolidate all phone account retrievals into a single method: getPhoneAccounts(...). Consolidate checks for capabilities, package-name, uri, and isVisibleForUser(...). This will be very helpful when implementing enable/disable for phone accounts. Bug: 20303449 Change-Id: I24d63cd313876f5d9390f2eb31c0ce79d7cb0ab2
* Add hidden methods to set/get default dialer across usersYorke Lee2015-05-041-1/+6
| | | | | Bug: 20696062 Change-Id: Ib26197c670caed9f2eab3e252c8fbc6102e0d476
* Call restoreCallingIdentity in finally blockYorke Lee2015-05-041-12/+18
| | | | | Bug: 20822416 Change-Id: Ideadd8093408defe761288ecb9c728637555f351
* Fix issues with UserManager.DISALLOW_OUTGOING_CALLYorke Lee2015-04-301-1/+3
| | | | | | | | | | | * Make sure the correct user is checked when using the TelecomManager.placeCall API. * Since a toast cannot be shown without an activity context, show the error using the ErrorDialogActivity instead. Bug: 20665346 Change-Id: I353cb009e8f90572a52b560259582180898370d2
* Add default dialer checks to Telecom/TelephonyYorke Lee2015-04-291-36/+28
| | | | | | | | | | | | | Check for the default dialer or the modify phone state permission for various TelecomManager/TelephonyManager methods. Make sure to check the user-selected default rather than the hardcoded package name. Exercise this code in TestDialerActivity. Bug: 20304458 Change-Id: Ic04cd8f2ba98e1d54c39549ae89d3e11cd5cdafb
* Simplify DefaultDialerManagerYorke Lee2015-04-281-6/+1
| | | | | | | | | | The previous code worked with ComponentNames because it was based off existing code for the default SMS application. We only really need the package name however, so simplify the code by storing and retrieving the package name directly. Bug: 20304458 Change-Id: Icabd3a9f0f8166c105360494b601160d13767fad
* Fix some logspamYorke Lee2015-04-271-1/+1
| | | | | | | | | No need to log the entire exception when the caller is not the default dialer. This can happen if the system (which has MODIFIY_PHONE_STATE) calls a method, and can be confusing when reading the logs. Change-Id: I1c48b2a12961ab000995114aed7fe519021549d7
* Add some comments to TelecomServiceImplYorke Lee2015-04-241-0/+3
| | | | Change-Id: I92d8e83a5f06a08f12e641f8cd9e910baa957caf
* Add APIs to getDefaultDialerPackage and getSystemDialerPackageYorke Lee2015-04-241-0/+24
| | | | | | | | | | | getDefaultDialerPackage is a public API and will be used by apps to determine if they are the default dialer. getSystemDialerPackage is a hidden API and is only used by system components. Bug: 20304458 Change-Id: Ifed855ccb8827cb2f62fd13f7c5afc307425ef29
* Handle outgoing call broadcast with Telecom's permissionsYorke Lee2015-04-241-0/+2
| | | | | | | | | | The default dialer may not have MODIFY_PHONE_STATE permissions anymore which is needed to start the outgoing call. We've already checked for permissions at this point so do the rest of the broadcast with Telecom's permissions. Bug: 20304411 Change-Id: I50cfa75ae27072237ea7b6b8fe2a5113b8d1d959
* Merge "Move CallState and rename PRE_DIAL_WAIT."Santos Cordon2015-04-241-1/+0
|\
| * Move CallState and rename PRE_DIAL_WAIT.Santos Cordon2015-04-231-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | CallState was a public API only being used by Telecom so I've moved it into to Telecom and removed it from the public API. The translation from CallState to Call.STATE_* was happening on the public Call object which wasn't ideal (Call.java shouldn't have to know that other representations of state exist). So I moved the translation into InCallController.java and what we pass into ParcelableCall is now Call.STATE_* constants. Bug: 20532827 Bug: 20532435 Change-Id: I79ce36c7e971c1a49b857506c9a56cfe316069cf
* | Add TelecomManager.placeCallYorke Lee2015-04-231-0/+27
|/ | | | | | | | | | | | | | | Places a new outgoing call using the system telecom service with the specified parameters. Making emergency calls using this method requires that the method-caller is either the user-selected default dialer app or preloaded system dialer app. Requires that the caller have the {@link android.Manifest.permission#CALL_PHONE} permission. Bug: 20348183 Change-Id: Ieedb5628e8c6be25137944e7c3639dc1d9bc61df