mirror of
https://github.com/carlospolop/hacktricks
synced 2024-11-25 06:00:40 +00:00
GitBook: [master] one page and 2 assets modified
This commit is contained in:
parent
1ea9767037
commit
a05e62d48a
3 changed files with 13 additions and 1 deletions
BIN
.gitbook/assets/image (551).png
Normal file
BIN
.gitbook/assets/image (551).png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.8 MiB |
BIN
.gitbook/assets/image (552).png
Normal file
BIN
.gitbook/assets/image (552).png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.3 MiB |
|
@ -15,6 +15,18 @@ This is some simple activity flow:
|
|||
|
||||
![](../../.gitbook/assets/image%20%28550%29.png)
|
||||
|
||||
### Android Multi-tasking - One Task
|
||||
|
||||
One task is composed by several activities
|
||||
|
||||
![](../../.gitbook/assets/image%20%28552%29.png)
|
||||
|
||||
### Android Multi-tasking - Several Tasks
|
||||
|
||||
Android usually manages several tasks
|
||||
|
||||
![](../../.gitbook/assets/image%20%28551%29.png)
|
||||
|
||||
## Task affinity and Launch Modes
|
||||
|
||||
**Task affinity** is an attribute that is defined in each `<activity>` tag in the `AndroidManifest.xml` file. It describes which Task an Activity prefers to join.
|
||||
|
@ -48,7 +60,7 @@ The victim needs to have the **malicious** **app** **installed** in his device.
|
|||
|
||||
## Preventing task hijacking
|
||||
|
||||
Setting taskAffinity="" can be a quick fix for this issue. The launch mode can also be set to **singleInstance** if the app does not want other activities to join tasks belonging to it. A custom **onBackPressed\(\)** function can also be added, to override the default behaviour.
|
||||
Setting `taskAffinity=""` can be a quick fix for this issue. The launch mode can also be set to **singleInstance** if the app does not want other activities to join tasks belonging to it. A custom **onBackPressed\(\)** function can also be added, to override the default behaviour.
|
||||
|
||||
## **References**
|
||||
|
||||
|
|
Loading…
Reference in a new issue