MASTG-DEMO-0035: Data Exclusion using backup_rules.xml with adb backup
Content in BETA
This content is in beta and still under active development, so it is subject to change any time (e.g. structure, IDs, content, URLs, etc.).
Download MASTG-DEMO-0035 APK Open MASTG-DEMO-0035 Folder Build MASTG-DEMO-0035 APK
Sample¶
This demo uses the sample from Data Exclusion using backup_rules.xml with Backup Manager.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
|
1 2 3 4 5 |
|
Steps¶
- Install the target app on your device.
- Open the app and exercise it to trigger file creations.
- Execute
run.sh
.
1 2 3 4 5 6 7 8 9 10 11 |
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
|
For simplicity, in run.sh
we restrict the files to the filesDir
directory in the backup structure (apps/org.owasp.mastestapp/f
).
Observation¶
The output contains:
output.txt
: the list of files from the backup.apps/org.owasp.mastestapp/f/
: the directory containing a copy of the backup files.
output.txt | |
---|---|
1 2 |
|
Evaluation¶
The test fails because secret.txt
is part of the backup and it contains sensitive data.
apps/org.owasp.mastestapp/f/secret.txt | |
---|---|
1 |
|
Note that backup_excluded_secret.txt
file is not part of the backup, which is expected as it was marked as exclude
in the backup_rules.xml
file.