android-backup-extraction
Extract app data from a non-rooted device via ADB backup when allowBackup is not disabled — unpack the .ab with android-backup-extractor and inspect shared_prefs/databases/files for secrets. Tier 1. Use when the manifest leaves allowBackup enabled. Aligns to OWASP MASTG MASVS-STORAGE.
AnandJogawade · Static checks on file
Installation
Read the source and dependencies before running a command. Copying does not install or execute anything.
npx skills add AnandJogawade/Zazy-Pentest-Plugin-for-Claude --skill android-backup-extractionAbout this skill
name: android-backup-extraction description: Extract app data from a non-rooted device via ADB backup when allowBackup is not disabled — unpack the .ab with android-backup-extractor and inspect shared_prefs/databases/files for secrets. Tier 1. Use when the manifest leaves allowBackup enabled. Aligns to OWASP MASTG MASVS-STORAGE.
Android Backup Extraction
If allowBackup is not explicitly false, pull the app's data off a stock device and mine it offline — no root required.
Trigger phrases
adb backup, allowbackup, backup extraction, android-backup-extractor, abe.jar, .ab file, backup.tar, offline data disclosure
Method
- Confirm backups are allowed —
aapt dump badging app.apk/ manifest showsallowBackupabsent or"true"(seeandroid-manifest-analysis). - Exercise the app (login, store data) so there is sensitive state to back up.
- Take the backup:
adb backup -f backup.ab -noapk <package>(confirm the on-device prompt; leave backup password blank for easiest unpack).
- Unpack:
java -jar abe.jar unpack backup.ab backup.tartar xvf backup.tar
- Inspect the extracted
apps/<package>/tree —sp/(shared_prefs),db/(databases),f/(files) — for plaintext credentials/tokens/PII (grep,sqlite3,strings).
Modern / rare techniques
- Password-protected backups: if a backup password is set,
abe.jar unpackprompts for it; crack weak ones offline or supply a known password. fullBackupContent/dataExtractionRulesgaps: even with rules, developers often forget to exclude a prefs file or DB holding tokens — diff what was excluded vs what holds secrets.- Auto Backup to cloud:
targetSdk 23+default cloud backup can expose the same data to the user's Google account; note it as an additional exposure path.
Escalation / chaining
Extracted tokens/session → account takeover via android-backend-api-testing; same data set as android-insecure-storage but obtained without root — use whichever path the engagement allows.
Backend & tooling
Preferred Kali path (native Kali / WSL+Kali / Kali-SSH / Kali-MCP / HexStrike). Needs the user's device/emulator (adb, physical confirm of the backup prompt) + Kali tooling (abe.jar/tar/sqlite3). Windows-local last resort. See zazy-orchestrator.
Verification (background, before reporting)
Confirm the backup is non-empty and actually contains sensitive data (open the file, verify the token is live) before reporting. Reproduce the unpack at least once independently.
Evidence
The allowBackup setting, the non-empty .ab/.tar, and the extracted sensitive file/value (redacted) with proof of sensitivity. Remediation: allowBackup=false; fullBackupContent/dataExtractionRules exclusions; encrypt sensitive data at rest.