Comments (5)
Hi, please format your issue by following the bug report issue template.
Moreover, if it's a problem of Apktool you should contact them!
from obfuscapk.
i try to use apktool versions
2.3.4 ,2.4.0,2.4.1 and 2.4.1 dirty
But getting rebuild time error in each version
Command :-
python3.7 -m obfuscapk.cli -p -w ~/Desktop/working-dir -d ~/Desktop/Obfuscated.apk -o ConstStringEncryption -o Nop -o RandomManifest -o Rebuild -o NewSignature -o NewAlignment virus1.apk
Encrypting constant strings: 100%|????????????????????????????|[00:16<00:00, 98.94file/s] |[00:00<?, ?obfuscator/s]
Running obfuscators (ConstStringEncryption): 17%|??|[00:54<04:32, 54.47s/ob Inserting "nop" instructions in smali files: 100%|??|[00:26<00:00, 61.77file
("Here i got stuck ")
Running obfuscators (Rebuild): 33%|???? |[01:21<03:04, 46.12s/obfuscator]08/04/2020 04:15:44> [ERROR][obfuscapk.tool.Apktool][build()] Error during build command: I: Using Apktool 2.4.1-dirty
I: Smaling smali folder into classes.dex...
I: Building resources...
W: aapt: brut.common.BrutException: brut.common.BrutException: Could not extract resource: /prebuilt/linux/aapt_64 (defaulting to $PATH binary)
W: First type is not attr!
W: A/ (21360): First type is not attr!
brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 134): [aapt, p, --min-sdk-version, 16, --target-sdk-version, 22, --version-code, 1, --version-name, 1.0, --no-version-vectors, -F, /tmp/APKTOOL276776660905134146.tmp, -0, resources.arsc, -0, png, -0, arsc, -I, /root/.local/share/apktool/framework/1.apk, -S, /root/Desktop/working-dir/virus1/res, -M, /root/Desktop/working-dir/virus1/AndroidManifest.xml]
08/04/2020 04:15:44> [ERROR][obfuscapk.obfuscation][build_obfuscated_apk()] Error during apk building: Command '['apktool', 'b', '--force-all', '/root/Desktop/working-dir/virus1', '-o', '/root/Desktop/Obfuscated.apk']' returned non-zero exit status 1.
08/04/2020 04:15:44> [ERROR][yapsy_loaded_plugin_Rebuild_1.rebuild.Rebuild][obfuscate()] Error during execution of "Rebuild" obfuscator: Command '['apktool', 'b', '--force-all', '/root/Desktop/working-dir/virus1', '-o', '/root/Desktop/Obfuscated.apk']' returned non-zero exit status 1.
08/04/2020 04:15:44> [CRITICAL][obfuscapk.main][perform_obfuscation()] Error during obfuscation: Command '['apktool', 'b', '--force-all', '/root/Desktop/working-dir/virus1', '-o', '/root/Desktop/Obfuscated.apk']' returned non-zero exit status 1.
Traceback (most recent call last):
File "/root/Obfuscapk/src/obfuscapk/main.py", line 88, in perform_obfuscation
(obfuscator_name_to_function[obfuscator_name])(obfuscation)
File "/root/Obfuscapk/src/obfuscapk/obfuscators/rebuild/rebuild.py", line 20, in obfuscate
obfuscation_info.build_obfuscated_apk()
File "/root/Obfuscapk/src/obfuscapk/obfuscation.py", line 396, in build_obfuscated_apk
apktool.build(self._decoded_apk_path, self.obfuscated_apk_path)
File "/root/Obfuscapk/src/obfuscapk/tool.py", line 93, in build
output = subprocess.check_output(build_cmd, stderr=subprocess.STDOUT).strip()
File "/usr/lib/python3.7/subprocess.py", line 411, in check_output
**kwargs).stdout
File "/usr/lib/python3.7/subprocess.py", line 512, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['apktool', 'b', '--force-all', '/root/Desktop/working-dir/virus1', '-o', '/root/Desktop/Obfuscated.apk']' returned non-zero exit status 1.
Traceback (most recent call last):
File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"main", mod_spec)
File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/root/Obfuscapk/src/obfuscapk/cli.py", line 81, in
arguments.interactive, arguments.ignore_libs, arguments.virus_total_key)
File "/root/Obfuscapk/src/obfuscapk/main.py", line 88, in perform_obfuscation
(obfuscator_name_to_function[obfuscator_name])(obfuscation)
File "/root/Obfuscapk/src/obfuscapk/obfuscators/rebuild/rebuild.py", line 20, in obfuscate
obfuscation_info.build_obfuscated_apk()
File "/root/Obfuscapk/src/obfuscapk/obfuscation.py", line 396, in build_obfuscated_apk
apktool.build(self._decoded_apk_path, self.obfuscated_apk_path)
File "/root/Obfuscapk/src/obfuscapk/tool.py", line 93, in build
output = subprocess.check_output(build_cmd, stderr=subprocess.STDOUT).strip()
File "/usr/lib/python3.7/subprocess.py", line 411, in check_output
**kwargs).stdout
File "/usr/lib/python3.7/subprocess.py", line 512, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command '['apktool', 'b', '--force-all', '/root/Desktop/working-dir/virus1', '-o', '/root/Desktop/Obfuscated.apk']' returned non-zero exit status 1.
Running obfuscators (Rebuild): 33%|???? |[02:08<04:17, 64.44s/obfuscator]
from obfuscapk.
May you try to disassemble and rebuild the apk with Apktool? Because it looks like a problem of Apktool
from obfuscapk.
May you try to disassemble and rebuild the apk with Apktool? Because it looks like a problem of Apktool
You can modify the above command to only try to repackage the application without any obfuscation:
python3.7 -m obfuscapk.cli -p -w ~/Desktop/working-dir -d ~/Desktop/Obfuscated.apk -o Rebuild -o NewSignature -o NewAlignment virus1.apk
If this works then the error is caused by one of the obfuscators, otherwise there's an issue with Apktool for this specific apk.
from obfuscapk.
well there is no problem in your tool
when i try to decompile and then re build any apk without making any change . it give the same error
so here apktool is the problem :)
and apktool developer aren't help in this case
i got (exit code 132 ) while rebuilding app
from obfuscapk.
Related Issues (20)
- Error obfuscapk BundleDecompiler HOT 12
- apktool error during rebuilding HOT 7
- unknown shorthand flag HOT 7
- About metasploit HOT 2
- apktool errror HOT 1
- About enc key HOT 1
- Whether About is Bundle Support aab? HOT 5
- obfuscate .JSON file HOT 5
- Failure with Rebuild obfuscator using *.aab file HOT 9
- this docker image can not support mac m1.
- 'docker run -v "/root/":"/workdir" obfuscapk -w /workdir/obfuscation_dir/ -o' can not run.
- class_rename incorrectly replaced the command
- path error HOT 2
- Encrypting strings in a java class or in the resources files HOT 3
- APK Tool OOM HOT 1
- TypeError: stat: path should be string, bytes, os.PathLike or integer, not NoneType HOT 1
- Failed install obfuscated apk. HOT 4
- sign bundle .aab with custom key
- Obfusca apk working on kotlin? HOT 1
- Apk Obfuscation and apktoll error i think
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 obfuscapk.