5

I was reading this article about task hijacking on Android: https://blog.dixitaditya.com/android-task-hijacking/

I tried the recommend fix but can still reproduce the issue. I also tried specifying package names of Instagram, Gmail app as android:taskAffinity value in the malicious app's Android Manifest and it redirected me to malicious app after clicking Instagram, Gmail. So, how come Gmail and Instagram is vulnerable to this or am i mistaking somewhere?

Is there a proper fix for this issue on Android?

Sher Sanginov
  • 431
  • 5
  • 9

2 Answers2

0

First I suggest you to understand task, launchModes and taskAffinity. Here's a google doc about these topics.

As a solution; you can use singleInstance. They are pretty similar, only difference is that, singleInstance keeps only one activity and even if you have multiple activities in back stack, they don't seem in different tasks, so that you see only one task in your Recents screen.

0

I see that a lot of apps are vulnerable for that. Only launchMode="singleInstance" or taskAffinity="..." protects against that, but it breaks many android features regarding activities navigation.

I'm really surprised that such serious vulnerability which was detected about 2015 has not been not fixed.

Vadik Sirekanyan
  • 3,332
  • 1
  • 22
  • 29