2

I'm trying to make a message application, which work along side the default messaging application. My application needs to intercept messages sent from a particular sender and not let default message application receive it. All other messages should be received by default message app. After some searching I found that this is not possible from Kitkat onwards unless my message app is the default one. Therefore I thought of deleting messages from the particular number in default message app's inbox after receiving. But from kitkat onwards it is not possible unless my app made default. Isn't there any way to do this?

What I want to do Receive messages from a user specified number only to my application while my application is not the default message application.

Community
  • 1
  • 1
pahan
  • 567
  • 1
  • 8
  • 22
  • There's a security hole in KitKat whereby a non-default app can get write access to the SMS Provider, but in all versions after 4.4, your app has to be the default messaging app to be able to delete from the inbox. – Mike M. May 28 '16 at 15:31
  • @MikeM. That means my task is impossible for versions > 4.4? – pahan May 28 '16 at 15:37
  • Yep, pretty much, unless your app is going to be the sender, too. – Mike M. May 28 '16 at 16:09
  • @MikeM. what changes my app being a sender? It isn't going to be the default app anyway. – pahan May 28 '16 at 16:24
  • If your app is just going to be talking to itself, you can use data SMS instead, which aren't saved in the Provider, and so won't show in any other apps. – Mike M. May 28 '16 at 16:27

0 Answers0