Comments (8)
This error seems to be caused by Apktool which apk-mitm
is based on. To narrow down the issue you could try manually decoding and re-encoding the APK without making any changes. For that, you can use the jar/apktool.jar
file bundled with apk-mitm
:
# Decode to "decoded" directory
java -jar ./apktool.jar decode android.apk --output decoded
# Re-encode to "android-reencoded.apk"
java -jar ./apktool.jar build decoded --output android-reencoded.apk
If that fails the issue is probably not something I can fix but rather an issue with Apktool or a mistake/oddity in TikTok's source code.
from apk-mitm.
Thank you very much, there's also an error when reencoding the apk file with just using apktool
from apk-mitm.
I found multiple issues related to the Syntax error: "(" unexpected
error you're getting on the Apktool repository. Two of them (#974 and #2092) are related to the ARM CPU architecture used by Raspberry Pi's. AAPT which is used by Apktool doesn't seem to work on ARM, so you can't use Apktool or apk-mitm
on your Raspberry Pi.
This makes me wonder: Are you getting the same error or a different one on your Arch installation?
from apk-mitm.
I'll try it running it on arch x64 again. It's weird that apktool is in the repository for raspbian...
from apk-mitm.
It's weird that apktool is in the repository for raspbian...
That is weird. Maybe that package is built using a patched version of AAPT or it used to work and just doesn't anymore.
from apk-mitm.
the raspbian version an older one (i think it was before 2.4) but decompiling works fine
and yeah doesn't work on x64 either
maybe its worth trying build for another sdk version?
java -jar apktool_2.4.1.jar build decoded --output reencoded.apk
I: Using Apktool 2.4.1
I: Checking whether sources has changed...
I: Smaling smali folder into classes.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes4 folder into classes4.dex...
I: Checking whether sources has changed...
I: Smaling smali_assets folder into assets.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes6 folder into classes6.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes2 folder into classes2.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes3 folder into classes3.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes7 folder into classes7.dex...
I: Checking whether sources has changed...
I: Smaling smali_classes5 folder into classes5.dex...
I: Checking whether resources has changed...
I: Building resources...
W: /home/marc/androidDecomp/decoded/res/values-v21/styles.xml:269: error: Resource entry j6 already has bag item android:windowContentTransitions.
W: /home/marc/androidDecomp/decoded/res/values-v21/styles.xml:268: Originally defined here.
W:
brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [/tmp/brut_util_Jar_10373368146805472863.tmp, p, --forced-package-id, 127, --min-sdk-version, 16, --target-sdk-version, 28, --version-code, 2021407050, --version-name, 14.7.5, --no-version-vectors, -F, /tmp/APKTOOL14351557212148640520.tmp, -e, /tmp/APKTOOL6742344768126141054.tmp, -0, arsc, -I, /home/marc/.local/share/apktool/framework/1.apk, -S, /home/marc/androidDecomp/decoded/res, -M, /home/marc/androidDecomp/decoded/AndroidManifest.xml]
from apk-mitm.
Ok the sdk version thing i suggested makes no sense. I guess the issue can be closed. Thank you very much :)
from apk-mitm.
No problem! Sorry I couldn't be more helpful here, but unfortunately there's not much I can do if Apktool can't decode or encode a certain APK. There's some issues about this Resource entry already has bag item
error on the Apktool repository, so I'd recommend taking a look at those and up-voting the ones matching your problem. Maybe someone has even found a way to solve this problem.
from apk-mitm.
Related Issues (20)
- Update Apktool HOT 2
- error: No resource identifier found for attribute 'enableOnBackInvokedCallback' in package 'android' HOT 6
- No resource found that matches the given name 'com.google.firebase.crashlytics'. HOT 2
- Is the using of the tool will lead to the absence of certificate pinning of the mobile app.
- Facing error for Uber app
- Any alternative for IOS app and how to bypass USB detection in android apk HOT 1
- apk-mitm installation?
- Allowing specific certificates --certificate broken - manual workaround
- error: unexpected element <uses-native-library> found in <manifest><application>. HOT 2
- Netflix not working HOT 1
- error in ubuntu and termux but not in windows, why? HOT 1
- ClassNotFoundException HOT 1
- "Error: ENOENT: no such file or directory" when opening AndroidManifest.xml HOT 1
- Doesn't work for Flutter and ReactNative
- could not align: could not execute zipalign HOT 2
- Androidmanifest invalid ampersand after patching
- Encoding process failed HOT 5
- Error while encoding APK file with apk-mitm and Apktool HOT 3
- After patching, not all endpoints can be monitored in Charles proxy HOT 1
- error: xml parser error: not well-formed (invalid token). HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apk-mitm.