History log of /frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
12f061938321d160112fbe8f52831b01d63657e6 22-Oct-2016 Ji Yang <yangji@google.com> Launch the default SMS app for notification action.

Use a broadcast receiver to launch the default SMS app when the user clicks
the new message notification.

Bug:30882932
Change-Id: I44c48043e94119d0886cf24f3518891168a54d17
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
d21e179e9f713631e269fe4a49272a6cd912c297 06-Jul-2016 Ji Yang <yangji@google.com> Merge "Pass non-null resultReceiver into filterSms." into nyc-mr1-dev
86da287ba153134ce662acf676a31bd91933a343 30-Jun-2016 Amit Mahajan <amitmahajan@google.com> VVM filtering should be done after carrier sms app.

Carrier app can be signed by a certificate present on SIM (app
will show up in CarrierPackage), or it can be a system app.
VVM filtering should not be between these 2; should be either
before them, or after, and we've decided to go with after for now.

Bug: 29899506
Change-Id: I2dfe0dce4e9d7f207b53275d594a6119c1224dba
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
97032e3f6ec2ebcd7258eae60d7c223339c116df 28-Jun-2016 Ji Yang <yangji@google.com> Pass non-null resultReceiver into filterSms.

BUG:29740091
Change-Id: If85beb9449a0831d5c4f5f588833ccd9546171ef
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
4953003ee8bf2ad759437837435301ef0c879dc7 10-Jun-2016 Ji Yang <yangji@google.com> Suppress new message notification on non-FBE devices.
am: 7abb62a097

Change-Id: I84d91dfc7e8fb118acbf5acfd6da64efc2f5411c
ae00825eaa816397f4bfaa9b1a61ce38c02930db 10-Jun-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Additional sms segment de-duping for multi-part SMS." into nyc-mr1-dev
54543184e3fd345fe0c96d4d96022ad4f058e410 26-May-2016 Amit Mahajan <amitmahajan@google.com> Additional sms segment de-duping for multi-part SMS.

Adding de-duping logic for segments with same parameters that can
cause ambiguity when concatenating them to get the complete
message.

Bug: 28932719
Change-Id: I187942d8384dc18d4311265441d076f085651c67
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
7abb62a0971290c1ad2e9e1be4a81cf4537cdc22 09-Jun-2016 Ji Yang <yangji@google.com> Suppress new message notification on non-FBE devices.

BUG: 28791378
Change-Id: Ib0e37cfdcc1b30ee1cbe21ad7398522113c8c976
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
b9b14f0b00a396295f6f91e5e83dbc8573f4de3b 08-Jun-2016 Ta-wei Yen <twyen@google.com> Calling as system when filtering VVM SMS in CarrierSmsFilterCallback

When the callback is invoked in CarrierSmsFilterCallback, the calling
identity is replaced with the carrier app.

VisualVoicemailSmsFilter need to be called from the system so the
calling identity must be restored before calling.

Change-Id: I03ad92aaefba58c57e76317cb30565a794a1c268
Fixes:28982677
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
bc417cdccca348a7607f9cdacc31b5b9f09ee410 26-May-2016 Ji Yang <yangji@google.com> Merge "Rename carrier messaging API constant name." into nyc-dev
am: bc94e86d20

* commit 'bc94e86d207f0dbf839c548f4cee0609e19bd15f':
Rename carrier messaging API constant name.

Change-Id: I54f9e31572262dea198cd90989c34b92e09c7e36
bc94e86d207f0dbf839c548f4cee0609e19bd15f 26-May-2016 Ji Yang <yangji@google.com> Merge "Rename carrier messaging API constant name." into nyc-dev
46fcf696e45525474d35f1a3e726c33d8429a596 23-May-2016 Amit Mahajan <amitmahajan@google.com> Merge "Add null check to avoid exception." into nyc-dev
am: d6ef8b2687

* commit 'd6ef8b268789f1202416149254ca16e33e27d74b':
Add null check to avoid exception.

Change-Id: If7151d5196d7e08ac434180bae6165abaa9d3b80
d6ef8b268789f1202416149254ca16e33e27d74b 23-May-2016 Amit Mahajan <amitmahajan@google.com> Merge "Add null check to avoid exception." into nyc-dev
d58649a2ea31306825ad7f21cbec0cd54ae32122 23-May-2016 Ji Yang <yangji@google.com> Merge "Revert "Revert "Remove the system new message notification automatically.""" into nyc-dev
am: 3ea0cc6163

* commit '3ea0cc6163742407ce9497c2c1348904d9dede5e':
Revert "Revert "Remove the system new message notification automatically.""

Change-Id: I122960a16e2752f36d4cc015a3ab8ed857eb6f21
8a54cdb7fdac1b325213a775939ccfc50dc65425 23-May-2016 Ji Yang <yangji@google.com> Revert "Revert "Remove the system new message notification automatically.""

This reverts commit de705fdb1d33c79ef676271fd6938120e15912f0.

The root cause was not caused by the original CL and it is now fixed.

BUG: 28874264

Change-Id: If250a2e59b8230fe54fdf5d35d3b669a70fe9a28
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
058f54014bdd6bc9585d39bb9872b7614c8bb63e 21-May-2016 Amit Mahajan <amitmahajan@google.com> Add null check to avoid exception.

Code was already added for b/28614514; moving it to check a little
earlier. Also adding another null pointer check.

This takes care of b/28842442 too.

Bug: 28883656
Change-Id: Ib8e29a7cc18bffa45a361c27a640fef791d6cafa
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
af65124e9b873a836e18ec0fa9ca8483ed4430b5 21-May-2016 Ji Yang <yangji@google.com> Merge "Revert "Remove the system new message notification automatically."" into nyc-dev
am: 90dc598127

* commit '90dc598127614cc6dc45f31592c75edc6b8fdf4c':
Revert "Remove the system new message notification automatically."

Change-Id: Idb4d105195883f60b5c1da49ac4083d5e95b8a7a
de705fdb1d33c79ef676271fd6938120e15912f0 21-May-2016 Ji Yang <yangji@google.com> Revert "Remove the system new message notification automatically."

This reverts commit d5059539e839b7bd1e9c62bbc0181444b38a6751.

Change-Id: I5fb1e9e000bc3cf59d6eb8c3a14c5c1fd908284f
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
4184a832bd9e271b342b160ed134e1aa7ed72a29 20-May-2016 Ji Yang <yangji@google.com> Rename carrier messaging API constant name.

BUG: 28842531
Change-Id: I5c8870034d2b19f7647c0dfef352d2d3c202986f
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
acd8f26d638420e10039135cd4b052349ee435f6 20-May-2016 Ji Yang <yangji@google.com> Merge "Remove the system new message notification automatically." into nyc-dev
am: 579a67f0eb

* commit '579a67f0eb5148bb6577a6734860b01112b59345':
Remove the system new message notification automatically.

Change-Id: Iff4b49c18f8fc3a55c60059cb2b324faccbc2258
d5059539e839b7bd1e9c62bbc0181444b38a6751 18-May-2016 Ji Yang <yangji@google.com> Remove the system new message notification automatically.

The notification is removed after user-unlock. It's no longer needed
at that point because the messaging app will show its own notification.

BUG: 28791378
Change-Id: I49f942e565cb8b830c763305483590323ba21e4b
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
3081824ff4942b9bd19db7a0d9918e188c7f69d1 14-May-2016 Ta-wei Yen <twyen@google.com> Add VisualVoicemailSmsFilter

Several implementation exists for OMTP-like visual voicemail SMS
interfaces because what type of SMS to use is not specified.
Before this CL we can only handle data SMS using the DATA_SMS_RECEIVED
broadcast. With this CL, we can handle data, text and type-0 SMS.

SMS filters will potentially do actions base on the SMS or drop it, so
proper priority should be established to make them work nicely together.

The android framework already provides the CarrierMessagingService
interface to filter SMS. There are 2 possible packages that implements
the interface, the carrier package and the system package. One of them
if any will be chosen to do the filtering. The carrier package is
installed with user interaction and have complex restraints. The
system package is preloaded by the OEM.

If there's a carrier package, we will filter after the carrier package
as it should have priority. If there's a system app, we will filter
before it as we offered mechanism to enable/disable us.

For type-0 SMS, we will filter it before it is going to be dropped.

We will filter visual voicemail SMS based on the content of the message.
A visual voicemail SMS should start with a certain prefix defined
through TelephonyManager, have a event field, and the rest of the message
is consist of OMTP key-value pairs. Future CL will add further
restrictions like originating number and destination port number to
reduce false positives.

If the parsing succeeded, we will compile it into a intent and send a
broadcast. The broadcast is to be made explicit in a future CL.

Bug:27816386
Bug:27817303
Change-Id: I120418d344a1537ff006583759659fa025cac712
(cherry picked from commit 0aa683b47dfd8590f71d88e0814dade4503f0b5d)
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
fc2150177a6c7a7f715822bd3390e91f3ab9b5dc 06-May-2016 Amit Mahajan <amitmahajan@google.com> Avoid carrier/system SMS filter if pdu(s) is null.

Bug: 28614514
Change-Id: Ia750d39af000a27b3d0b78281cf8fb949f003de3
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
6e4abd849e12860a7459f7ec74496ca02b9d7ee0 28-Mar-2016 Amit Mahajan <amitmahajan@google.com> Changes to de-dup messages in SMS raw table.

Bug: 27820591
Change-Id: Ie3a28cdbbb533c74f456b7e942ddfc2cd0d66bb0
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
0acde342e973a838a46eebf57a03a5fcad12708e 04-Apr-2016 Amit Mahajan <amitmahajan@google.com> Revert "Changes to de-dup messages in SMS raw table."

This reverts commit 8fe2baabaae75ab2975fb642db9a91db75d1a11e.

Bug: 27974596
Change-Id: Id5284e9f3da34b028e0097dc8f0e43a98e3a7a86
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
8fe2baabaae75ab2975fb642db9a91db75d1a11e 28-Mar-2016 Amit Mahajan <amitmahajan@google.com> Changes to de-dup messages in SMS raw table.

Bug: 27820591
Change-Id: I6b071ec99a90d9f5195825ba3cd73cb54f61631b
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
f307663682427b9b0602ed827759aef63bd3c9e9 10-Mar-2016 Ye Wen <ywen@google.com> Use foreground intent for received SMS and MMS WAP Push

b/27471638

Change-Id: I400f0b27768468962a2394dc84bd37029c26b53b
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
3fcaeac48c45f7fbefd2aeee8fe3094f40f9bf84 24-Feb-2016 Ji Yang <yangji@google.com> Adapt to carrier message service API change.

Check message filter callback result to decide whether to
show new message notificaiton.

BUG: 27292180

Change-Id: Idbf9715e16d099dbdd9f832821e613ca704720df
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
27f471647b2da3ff50620a766c048ebef8d45ae1 18-Feb-2016 Amit Mahajan <amitmahajan@google.com> New unit tests for InboundSmsHandler.

Bug: 25691379
Change-Id: I5fcbc95467cc7bd75f3f8a7da42c3814c1d2dac8
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
0c342d95e06f85fa56e576025ebcf4f70bc04d67 16-Feb-2016 Amit Mahajan <amitmahajan@google.com> Merge changes Ic8e5b8c9,I08edb714 into mm-wireless-dev
am: 7efd41c8db

* commit '7efd41c8dbd2822c53bfddeb10a612c916a7daff':
Unit tests for CallForwardingOption in GsmCdmaPhone
Support for storing voicemail count for multi-sim.
97b3c4e45f156d8d5ae25a32357c9b31e018da32 10-Feb-2016 Amit Mahajan <amitmahajan@google.com> Support for storing voicemail count for multi-sim.

Bug: 18108420
Change-Id: I08edb714b839b44472b3b7a4d0aba287da2969d3
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
250eb25b03c992049bff818c4762c45b44110fb4 17-Feb-2014 Fredrik Henricsson <fredrik.henricsson@sonymobile.com> Do not accept incoming SMS when device is in cryptkeeper.

When an SMS message is received while the user is making an
emergency call from the Cryptkeeper screen, all incoming SMS
messages will be lost. This fix results in the device responding
to the network that the SMS message could not be delivered.

Explanation:
When a user makes a call from the Cryptkeeper screen there is no
broadcast receiver that can handle the incoming message. In this case
telephony will try to persist the message in the database, but as the
phone is encrypted it silently fails, while responding to the network
that the message has been received and processed.

Bug: 26981948
Change-Id: Ib3f7e749b7734a5957383b03049a7a5b463915f4
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
4d08cf9c93ee762a345aa64c292ca065aa5e51c2 03-Feb-2016 Amit Mahajan <amitmahajan@google.com> Merge "Unit test for CdmaInboundSmsHandler" into mm-wireless-dev
am: 73ea88040f

* commit '73ea88040f7b17b3d0799c5918349adb68df3902':
Unit test for CdmaInboundSmsHandler
52f23cd068ffc05a2aaa101472d36a2861e55f29 27-Jan-2016 Amit Mahajan <amitmahajan@google.com> Unit test for CdmaInboundSmsHandler

Bug: 25691379
Change-Id: I523a9ccace6e00d4865cd682f242ed5a1d7e9afe
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
270e2658281af04247c4fca07a60c39f37f37199 01-Feb-2016 Amit Mahajan <amitmahajan@google.com> resolve merge conflicts of 003753ff3b to master.

Change-Id: I75538817050719a9bede694e9a42a2eebcfe83d2
604d70ccbf958d1abd92b128fa18a9f17b42b133 30-Jan-2016 Amit Mahajan <amitmahajan@google.com> Cleanup access modifiers.

This is useful for tests. CL also includes minor cleanup in SST.

Bug: 25793157
Change-Id: I068af6bfd9ea9e04e95244d23f830731aef38ee1
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
72f7fc997b09204bf01ccaac34ac4b9bd91d954b 27-Jan-2016 Ji Yang <yangji@google.com> Check wap push type before showing new message notification

Bug: 26232405
Change-Id: Id8dc622dd058856c70d20de0fe879711c3048a04
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
8f21e0c6528f015924d153350dd2a717d3b51f66 21-Jan-2016 Ji Yang <yangji@google.com> Postpone inbound SMS processing until credential-encrypted storage is unlocked.

A notification will be shown to the user and the inbound SMS will be kept
inside the raw table until credentail-encrypted storage is unlocked.

Bug: 26232405
Change-Id: I2854ced55d911ccaf61df908d7c00f8acd5fae51
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
b88ccd9f208e48f7e5154d9c831dcaaf4e67beb7 25-Jan-2016 Abhijith Shastry <ashastry@google.com> Merge "Block SMS, and MMS from blocked numbers."
ba51280f53e677ac527b11bd9a5dfa819740f70a 22-Jan-2016 Abhijith Shastry <ashastry@google.com> Block SMS, and MMS from blocked numbers.

BUG: 26682753
Change-Id: I464c04466d3a936d2d611cbaf791490340a9f515
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
ec334adf4017ca172f44612d01456e671f922344 19-Jan-2016 Amit Mahajan <amitmahajan@google.com> First unit test for SMS (EVENT_NEW_SMS in GsmInboundSmsHandler).

Bug: 25691379
Change-Id: Iacb24b23c224a8889cc549d02aa0dbd415e3c3d7
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
1a87ab3d7170d618f048c4f5af8c7504a587aaa5 10-Dec-2015 Jack Yu <jackyu@google.com> Merge from master

Change-Id: Ifbd86600111d2c444031ff608fab62fb2ee4b236
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
6c806ef816f8ae0a1849ba05f3128a04577b32d0 25-Nov-2015 Amit Mahajan <amitmahajan@google.com> Phone refactor Phase II. Renamed PhoneBase to Phone.

Phone interface has been renamed to PhoneInternalInterface. For
outside world, Phone is now the only handle that should be used
for phone related classes (earlier there were Phone, PhoneBase,
GSMPhone, etc.). Some cleanup is still pending to make sure
technology specific phone is not used outside of telephony at all
(and even within telephony as much as possible).

Bug: 25793157
Change-Id: Ic19b286e6d2580e5537f4f6a8dc8afe39d80a803
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
ba798021d26fc3690a16a2c9b4f41f44a1122b49 13-Oct-2015 Amit Mahajan <amitmahajan@google.com> Require receivers of WAP_PUSH_RECEIVED to have MMS/WAP_PUSH permission

Earlier the permission was RECEIVE_SMS which was incorrect.

Bug: 24806190
Change-Id: I6805c7ccb2e5b30bfdf4914014de94db7b841539
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
65bd5856a33708f3b690dcb7703b7ce5acfd66e0 04-Sep-2015 Xiaohui Chen <xiaohuic@google.com> Cleanup USER_OWNER in telephony

Bug: 19913735
Bug: 23795305
Change-Id: Id52c4558c56d1006b975f27f65e061a623978b8f
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
4fa569c2b8a15f388c7267a0ac9de755e8b6dff1 27-Jul-2015 Amit Mahajan <amitmahajan@google.com> Merge "Change to not delete part of multipart SMS when waiting for other parts" into mnc-dev
c2c4cea90515e932c8afbe285f4436dbcf9dada4 27-Jul-2015 Amit Mahajan <amitmahajan@google.com> Change to not delete part of multipart SMS when waiting for other parts

Bug: 22761826
Change-Id: I947a82c15f0df50350886daceca8fa592b8bf589
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
63068219ff1cd35cc856327e6c7514e8ea9e6359 25-Jul-2015 Amit Mahajan <amitmahajan@google.com> Merge "Change to make sure InboundSmsHandler stm gets out of DeliveringState" into mnc-dev
22da42acec88a985c9da6aa1095e5cbb50bd5f32 24-Jul-2015 Amit Mahajan <amitmahajan@google.com> Change to make sure InboundSmsHandler stm gets out of DeliveringState

Bug: 22673185
Change-Id: Icdd972845660bab2b4b26e0c3fc3a174868dbb8b
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
25ba0c3660ef78bbdaf2f4db7b3e7a833c377ccb 22-Jul-2015 Dianne Hackborn <hackbod@google.com> Fix issue #22612630: Ensure SMS/Call delivery during Doze

Place apps on whitelist when delivering SMS, like MMS.

Change-Id: Ied719152e84ba88cb2c224ed1669cb12c1412ee7
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
932f590aadc3cfac86cc3972db5eb7013f94780d 14-Jul-2015 Dianne Hackborn <hackbod@google.com> Fix issue #21626564: MMS should be receivied while Dozing

Uses new APIs to put apps on the whitelist as needed.

Change-Id: I24bf0c00f2a7dca64590e7fc0dd6ec036e9bd2bf
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
e70617d81dcd42350a737b11c25532e1d43df4ff 22-Jan-2015 Legler Wu <legler.wu@mediatek.com> [DS] Correct the access method for telephony system property

Revise the method to access telephony system property.
Add several PROPERTY_XXX_XXX_MSIM for MSIM type system properties. If
caller use the old one, it will be dispatched to new one and get by
default phone id.
Ex. PROPERTY_ICC_OPERATOR_NUMERIC

Bug: 18675498
Change-Id: I68b4de1817bb5a34d4a54685332f856e79a39d60
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
062a2a3838c8d8adf16f4d9fbde8d52450da0336 13-Jan-2015 Shishir Agrawal <shishir@google.com> Make UICC code subID-less.

MSIM code introduced code in the UICC objects that refer to the subIds.
This is potentially very dangerous becuase subIds are only initialized after
the UICC object is completely initialized. Hence using subId in the UICC code
could lead to lots of properties being not set correctly.

The new code, uses the phoneId everywhere within the UICC code, which is
initialized when the UICC object is created and will remain constant for the
lifetime of the UICC object.

Bug: 18748407
Change-Id: I1f50abc40b8592751cdeca2de2c76ac9f2d40768
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
473eaf181c0964e3b04bdd71307056c78d484abc 09-Dec-2014 Cheuksan Wang <edwang@google.com> Clear calling entity before deleting SMS from raw table.
Deletion needs permissions of the phone process.

BUG: 18672706
Change-Id: If70b69745f5b09c644720ba019b409a82efb8033
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
cf924dde47f17d85359d947ad8752f6000a97a59 05-Dec-2014 Jing Zhao <zhaojing@motorola.com> Add checking to find AppDirectedSmsProxy for App Directed SMS feature

To integration with AppDirectedSmsProxy,
which proxy extends CarrierMessagingService for App Directed SMS feature.
InboundSmsHandler needs to add a checking to look for system service with intent entry
'CarrierMessagingService.SERVICE_INTERFACE',
so that could find AppDirectedSmsProxy and bind such service.

Bug: 18609762
Change-Id: I80a133653101cd4ec1793e726faf3601e2970224
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
8215559cd1141ac90c478fd3df75e43c9d755c6c 01-Nov-2014 Cheuksan Wang <edwang@google.com> Use the AIDL based API to communicate with the carrier app.

Implements SMS sending.

BUG: 18005911

Change-Id: I467036b59b51905532e7ce1591dcb2e2856ef2d3
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
ed0cfa93b9e42486bfc7caeca83ceae1a2f7328e 25-Oct-2014 Abhijith Shastry <ashastry@google.com> Implements platform changes to use the AIDL based API to communicate with the carrier app for SMS filtering.

BUG: 18005911

Change-Id: Ibc52fe4d4e5b73dc82ab3569a9818730d4acd5a3
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
26a4150cfb8cd317eb64994b9d9fd6109bd87ba7 03-Jan-2014 Sukanya Rajkhowa <srajkh@codeaurora.org> Telephony: Voice mail notification related changes

* Separate voice mail notify from SIM/RUIM card

* For GSM store voice mail count in phone memory
irrespective of SIM write result.

* Display voice mail count for GSM

Bug: 17299884

Change-Id: I368bfb98c8798ed1f43bcc330e6d97e8f95f0f54
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
934a24a6aa2b7a981e872fa350648904ed80280a 28-Aug-2014 Diego Pontoriero <diegs@google.com> Generalize getCarrierPackageNamesForBroadcastIntent utility method to work for all intent types.

Bug: 17163860
Change-Id: I4b013db09a521fbc41401e11cd60a0c7b0172b64
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
8d135fd107e64d9bbdc082c2fdf45c6f494cafd3 26-Aug-2014 Amith Yamasani <yamasani@google.com> Don't invoke resultReceiver more than once

When delivering the SMS_RECEIVED broadcasts to multiple users,
don't invoke the resultReceiver for each of them. Only invoke
for the primary user.

Bug: 17058511
Change-Id: Id59c8c7b1cbaf1d7d7fd05134465e1987cded817
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
4cab4152bd6d47059e4d7cb352b5f5add938c318 20-Aug-2014 Shishir Agrawal <shishir@google.com> Adding loggin to InboundSmsHandler.

To be able to detect crashes due to improper state transitions.

Bug: 17058511
Change-Id: I2893d7c1a5f4afaa77cd10429fb4a8738f79b980
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
a2ce002a0327f0deb079cc6acad1c493e6ded442 05-Aug-2014 Amith Yamasani <yamasani@google.com> Make SmsApplication handle multiple users

Assume that there's one default app per user. Apps should be able
to register as the default app for even secondary users.
Read and write to the correct settings db.

Deliver DELIVER broadcast to primary user.
Deliver RECEIVED broadcast to all permitted and currently
running users.

Bug: 16681533
Change-Id: I08cf5318f267a8c55ac427ac2c3573b4319b5193
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
7f1a3f0ab65c144fde56e1246c5747b0c555034a 23-Jul-2014 Shishir Agrawal <shishir@google.com> UiccCarrierPrivilegeRules: changing getCarrierPackageNamesForBroadcastIntent to return a list.

Currently it returns the first matching package name. Now it will return a
list of all matching packages.

Change-Id: Icc0fc728e1e24235632ac38a482b06a7b829de78
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
951b6a916c88ba25064bf4c7777eafdf86bc4622 22-Jul-2014 Shishir Agrawal <shishir@google.com> NPE fix in InboundSmsHandler.

Bug: 16445149

Change-Id: I79cd51d39442fe27ff07b58d04ab35c00a6dacb2
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
a9552aa6bf3ce12c75ad43165034d9a1233fb131 21-Jul-2014 Shishir Agrawal <shishir@google.com> CarrierApp: Do not send broadcast if there is no carrier app.

Avoids an unnecessary broadcast.

Also fixes an NPE bug.

BUG=16454767
Change-Id: Idc8bff4c7a35b7ea0bb7446cd74515cf1675868d
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
f1aeeb51f2c62420012122e0ccc75b3940c570e4 15-Jul-2014 Ye Wen <ywen@google.com> Messaging auto persist switch (2/4)

b/14095333

Change-Id: I9dccdadd72d951d86f83cb7adea9b2f09fad08ce
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
c9394399180abbc32d04f6a3652ce22d5931e0b8 14-Jul-2014 Shishir Agrawal <shishir@google.com> Protecting messagings APIs for carrier access.

APIs protected by this CL:
- SMS injection.
- SMS filtering.
- SMS outbound broadcast.
- SMS outbound broadcast result.

Also moved much of the carrier checking logic from PhoneInterfaceManager to
the UiccCarrierPrivilegeRules for reusability.

BUG=15993876

Change-Id: I8309a1de23426dcc66a10383335cff9242920410
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
b29851580bba4a13ddbf7a534d8b09295eb2c60f 10-Jul-2014 Ye Wen <ywen@google.com> New SMS and MMS APIs and semantics (2/4)

1. Rest of the new SMS and MMS APIs
2. Auto persisting MMS WAP Push
3. Partial multi-sim support
4. New SMS/MMS database columns: archived and creator
5. Record message creator
6. Mms config access APIs

b/14095333

Change-Id: Idb0ab75384b2c949f1a6ebe8f1c33e90a06a4d9b
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
cafda9904d2804959d51697cdc63a185e687cb98 12-Jul-2014 Colin Cross <ccross@google.com> Revert "New SMS and MMS APIs and semantics (2/4)"

This reverts commit c5f9236283882b8e08390ac52e5b1fab2d3bc2fb.

Change-Id: I9585dabfc31611e68718859ea509b8f52535d9b5
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
c5f9236283882b8e08390ac52e5b1fab2d3bc2fb 10-Jul-2014 Ye Wen <ywen@google.com> New SMS and MMS APIs and semantics (2/4)

1. Rest of the new SMS and MMS APIs
2. Auto persisting MMS WAP Push
3. Partial multi-sim support
4. New SMS/MMS database columns: archived and creator
5. Record message creator
6. Mms config access APIs

b/14095333

Change-Id: I9a4261753a803f520933b643c0bac708ab9f40a9
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
370971c25973d9d8061b76e756df2fb8c1ebd990 28-Jun-2014 Ye Wen <ywen@google.com> MMS auto persisting (2/4)

1. Added new MMS message box type for failed messages
2. Use global static flag to temporarily turn off new SMS API semantics

b/14095333

Change-Id: I150a08a4b26bba6f3a7a1d8f848fe07c8be9298b
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
fce79caf5d7628cde43c5f0cd3d369673bc15212 27-Jun-2014 Ye Wen <ywen@google.com> Send persisted SMS message URI through intent

1. Sent message URI is passed via sentIntent in sending API calls
2. Received message URI is passed via SMS deliver or received intent

Change-Id: I02ffd5294e41b2f81b03f79fc008bba44cf33d9f
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
f68da23264bb06736b62e9c1b95225f6ec997ca8 26-Jun-2014 Ye Wen <ywen@google.com> Auto persist received SMS

Change-Id: I729b9eef0c77b35704e51547169700c5d3e989c5
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
6a22a5cf0ca0783b2f33b8f7ab8f3a37755aafcf 19-Jun-2014 Cheuksan Wang <edwang@google.com> Merge "Add SMS filtering intent and API for message deduping by the carrier app."
913880b94d8b29d8dec34b2307c313e2180eb6f0 27-May-2014 Cheuksan Wang <edwang@google.com> Add SMS filtering intent and API for message deduping by the carrier app.

If a carrier app is active, the SMS_FILTER intent is sent for every
incoming SMS message. If the carrier app considers this message as a
duplicate, it may set a status code to filter out this SMS. It may
also set a pdu in result extras to overwrite the pdu.

Change-Id: I41526b21df31142b8f6373f3aefbe360c5938af3
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
91f8e19cdafe6382ec1469167e208e2e928123cc 13-Jun-2014 Wink Saville <wink@google.com> Merge "Merge kwd to master"
a8467dd0c524787104b1ccdddc5e8af10ba729ed 13-Jun-2014 Wink Saville <wink@google.com> Merge kwd to master

Change-Id: Idb607c0aa32f80fe4fe1539aedea7a221e9e7f04
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
63418bbd2a9d7cc88ae24cc5ae776c01d688fc3a 03-Jun-2014 Anil Muthineni <anilmuthineni@google.com> Add api to inject SMS PDUs

Change-Id: I58a518a7a6d6f43fef3d989bc0c8b21959404ed0
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
d2feaf918ab0c1173d4ada182532e48d0c0d3f77 31-Oct-2013 Wink Saville <wink@google.com> When phone changes update InBoundSmsHandlers and CellBroadcastHandlers.

Without this change for devices where the phone can change, for instance
on N5 with Sprint the phone will change from a GSMPhone to a CDMALTEPhone
and messages will not be sent to the appropriate handler.

For Sprint this was most readily seen when the voice mail notification
wasn't sent to the notification manager.

Bug: 11254397
Change-Id: Ia0e764cf6fa04208a7e194a35435f251a177309f
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
5bc59fe360f396811723ce8f0fbb462504edda2a 17-Oct-2013 David Braun <dabraun@google.com> Do not allow SMS event receivers to abort the broadcast

This prevent apps from aborting the SMS related broadcasts so that all
apps interested in seeing them will now receive the broadcast.

Bug: 11259375 Do not allow apps to abort SMS/MMS broadcasts
Change-Id: I2620899b580b8861efebcc39408c875b4033cc53
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
5c3b6658d82f3af57161d5a34385dd95ea0f1abb 16-Sep-2013 David Braun <dabraun@google.com> Implement new method for handling SMS/MMS on the platform

Multi project change:
The changes in this project implement the actual change in the SMS related
intent behavior (defining and using the new events).

Bug: 10449618
Change-Id: Ia707ed561d89428db78203a2ed54504d867a3e43
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
8b61e10b480d3a7bae41025a97f3bd27ee5ed610 11-Sep-2013 Jake Hamby <jhamby@google.com> Fix receiving multi-part CDMA WAP messages.

Fix ArrayIndexOutOfBoundsException in CDMA WAP message handling.
Add a new flag to raw DB table to indicate 3GPP2 WAP PDU messages.
Use the new flag to return the correct value for getIndexOffset()
in InboundSmsTracker.

Previously this only worked correctly for single-segment WAP PDUs
of type WAP push.

Bug: 10595053
Change-Id: I8820da124e8fa4707cbee0398690a475d26ff702
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
90271d9ef1377b25b78359039fb2e87f32aba25b 04-Sep-2013 Sungmin Choi <sungmin.choi@lge.com> sms: Add exception code instead of low memory status

Add exceptoin code, after receiving Duplicated SMS.

Bug: 10484923
Change-Id: Ic9465adeb8a09d11fdd2e5b35108410baf56a2fc
Signed-off-by: daehun.ju <daehun.ju@lge.com>
Signed-off-by: Sungmin Choi <sungmin.choi@lge.com>
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java
0d4bcdf379842af4b6304809156971e926f374f0 18-Mar-2013 Jake Hamby <jhamby@google.com> Refactor inbound (MT) SMS handling into new handler classes.

Moved all MT SMS handling to separate StateMachine classes, which
save all incoming PDUs in the SmsProvider "raw" table, previously
used only for storing PDUs of concatenated messages. Then we ACK the
message, before starting the ordered broadcast as usual. If a receiver
of the broadcast sets the status to failure, we ignore it, but in the
future we could provide a mechanism to redeliver the broadcast.

New classes are (without com.android.internal.telephony prefix):
- CellBroadcastHandler
- InboundSmsHandler
- InboundSmsTracker
- SmsBroadcastUndelivered
- WakeLockStateMachine
- cdma.CdmaInboundSmsHandler
- cdma.CdmaServiceCategoryProgramHandler
- gsm.GsmCellBroadcastHandler
- gsm.GsmInboundSmsHandler

This fixes a bug in the SMS dispatcher. Previously we delivered
incoming SM's as ordered broadcasts and then sent an acknowledgment
to the SMSC after the broadcast completed. It was possible for the
ordered broadcast to take over 20 seconds to complete, causing SMS
retransmissions because we didn't ACK quickly enough. Also, a
broadcast receiver could set the result code to failure (the AOSP
MMS app never does this), causing us to negatively acknowledge the
SMS, potentially leading to many retries and a backlog on the SMSC.

The reason for saving all PDUs in the raw table before ACKing is so
InboundSmsHandler can handle the failure case of a device crash or
power failure in between ACKing the message and the delivery of the
ordered broadcast to receivers. This is handled when the Phone class
starts, creating a new thread to run SmsBroadcastUndelivered.
This Runnable scans the raw table once, finding all complete
PDUs and sending IncomingSmsTrackers to the state machine to
broadcast them again to receivers. In the worst case, a message might
be added twice to the MMS inbox, but it won't be lost.

However, due to the current MMS app implementation, which immediately
acknowledges the ordered broadcast before starting a new Service to
process the message, there is a very short window of time when a
message could potentially be lost, if the MMS app or device crashed
after the ordered broadcast returns and the message is deleted from
the raw table, but before the MMS service has added the message to
its own tables. To fix this will probably require API changes.

Another improvement from this change: SmsBroadcastUndelivered also
deletes PDUs for incomplete multipart messages that are older than
30 days. We've never garbage collected this table in the past, so
it's possible for a phone to accumulate a number of old PDUs in the
raw table if not all components arrived successfully.

The wake lock handling is also improved in this version, as we now
acquire a wakelock when the state machine leaves the Idle state,
releasing it 3 seconds after returning to the idle state, instead
of the previous 5-second timeout. If a new SMS arrives while a
broadcast is being delivered, we add it to the raw table and ACK the
new PDU immediately, then send the InboundSmsTracker as a message to
handle when the previous broadcast completes.

In order to keep track of whether a PDU is in 3GPP or 3GPP2 format,
the destination port column of the raw table is extended with three
flags: 3GPP format, 3GPP2 format, and no destination port present.
Because the destination port is a 16-bit value in both 3GPP and
3GPP2, the upper bits of the destination port can be used for flags.
This saves us from having to modify the SMS provider to update the
DB version and to add extra columns to keep track of these flags.

Bug: 7099232
Change-Id: Ibbc01ccb83320f4b6112fe3dd31355eb6f570b67
/frameworks/opt/telephony/src/java/com/android/internal/telephony/InboundSmsHandler.java