apk-mitm
apk-mitm copied to clipboard
Can't patch the app
I was able to patch previous apks of this app but latest version caused this error for me:
(base) murad@murad-HVY-WXX9:~/Downloads$ apk-mitm com.deliveroo.driverapp.22653.apk
╭ apk-mitm v1.2.0
├ apktool v2.6.0
╰ uber-apk-signer v1.2.1
Using temporary directory:
/tmp/apk-mitm-e9db742b0739046637bb25c4a84738f3
✔ Checking prerequisities
✔ Decoding APK file
✔ Applying patches
❯ Encoding patched APK file
↓ Encoding using AAPT2 [skipped]
→ Failed, falling back to AAPT...
✖ Encoding using AAPT [fallback]
→ I: Building resources...
Signing patched APK file
Failed! An error occurred:
I: Using Apktool 2.6.0
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether sources has changed...
I: Checking whether resources has changed...
I: Building resources...
W: invalid resource directory name: <tmp_dir>/decode/res navigation
brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [/tmp/brut_util_Jar_124675231844353432457461036289540206023.tmp, p, --forced-package-id, 127, --min-sdk-version, 23, --target-sdk-version, 30, --version-code, 22653, --version-name, 22.02.09_22653, --no-version-vectors, -F, /tmp/APKTOOL2235762449803605412.tmp, -e, /tmp/APKTOOL9931290549659700609.tmp, -0, arsc, -I, <tmp_dir>/framework/1.apk, -S, <tmp_dir>/decode/res, -M, <tmp_dir>/decode/AndroidManifest.xml]
The full logs of all commands are available here:
/tmp/apk-mitm-e9db742b0739046637bb25c4a84738f3/logs
I have the same problem, is there any solution?
I have the same problem with Brawl Stars downloaded from here:
https://apkpure.com/brawl-stars-android/com.supercell.brawlstars/download/43238-XAPK-61673947aeac73768556e7319e51a01d?from=variants%2Fversion
I had the same problem, I provided --wait flag in the argument and in waiting state, I have removed android:localeConfig="@xml/locales_config"
from AndroidManifest.xml file. and it worked.
specify a path newer version of apktool.jar with the --apktool flag