Skip to content

madkarmaa/apk-toolbox

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

112 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

APK toolbox

Compile and decompile Android applications with ease.

About

APK toolbox is a CLI wrapper around essential Android reverse-engineering and build tools (like Apktool). It streamlines the compilation and decompilation process so you don't have to remember long, complicated commands to do the job yourself.

It also provides full support for handling split APK formats, such as .xapk and .apks.

Downloads

Windows x64 Android arm64-v8a Linux x64 (GCC) Linux x64 (static) MacOS (Apple silicon)

Note

The Android binary is designed to run in a Termux environment.

Requirements

  1. Java JDK > 11
  2. Apktool
  3. APKEditor
  4. Android SDK Build Tools - no Android Studio?

Note

On Termux, the Android SDK Build Tools can be installed via

pkg install aapt2 apksigner -y

Android SDK Build Tools without Android Studio

  1. Download the Android SDK Command Line Tools
  2. Unzip the downloaded file
  3. Run
./cmdline-tools/bin/sdkmanager --sdk_root="." $(./cmdline-tools/bin/sdkmanager --sdk_root="." --list | grep "build-tools" | sort -t';' -k2 -Vr | head -1 | awk '{print $1}')

PowerShell:

./cmdline-tools/bin/sdkmanager --sdk_root="." (./cmdline-tools/bin/sdkmanager --sdk_root="." --list | Select-String "build-tools" | Sort-Object { [version](($_ -replace '.*build-tools;(\S+).*','$1') -replace '-rc\d+','') } -Descending | Select-Object -First 1 | ForEach-Object { ($_ -split '\|')[0].Trim() })
  1. Accept the license agreements
  2. The Android SDK Build Tools will be downloaded in build-tools/<VERSION>

Usage

Use either the help <cmd> command or the --help (-h) flag. The program will also guide you with errors.

Known issues

  • On Windows CMD, configuring a directory ending with a \ while wrapping it with double quotes " (such as "C:\Some\Example\Path\") will result in a Path not found error.

Build from source

Make sure you have the Rust toolchain installed.

git clone https://github.com/madkarmaa/apk-toolbox
cd apk-toolbox
cargo build --release --locked

Important

To build for Android (aarch64-linux-android), you must have Docker running. Install and use cross instead of cargo.

cargo install cross --git https://github.com/cross-rs/cross
cross build --release --target aarch64-linux-android --locked

The compiled binary will be available in the target/release/ directory (or target/{target}/release if cross-compiling).

Contributing

Contributions are welcome! Feel free to open an issue or submit a pull request if you'd like to improve the tool or fix any bugs.

License

This project is licensed under the MIT License.

About

Compile and decompile Android applications with ease, no need to remember complex commands

Topics

Resources

Stars

Watchers

Forks

Releases

Contributors

Languages