Skip to main content

๐Ÿ› ๏ธ APK/JAR Patching Tools

Utilities for patching Android Apps and JARs.


apktoolโ€‹

Runs apktool with custom arguments.

ArgumentDescription
ARGApktool options
apktool --help
apktool d -f "/sdcard/app.apk" -o "$TMP/output"
warning

It is recommended to use dynamic_apktool to avoid errors.


signโ€‹

Runs zipsigner with custom arguments.

ArgumentDescription
ARGZipsigner options
sign --help
sign "/sdcard/app.apk" "/sdcard/app_signed.apk"

decode_xmlโ€‹

Decodes an AndroidManifest.xml file.

ArgumentDescription
XMLXML file
decode_xml "$TMP/AndroidManifest.xml"
note

It is NOT necessarily compatible with other types of encrypted XMLs, nor of res/layout, res/drawable, ...


encode_xmlโ€‹

Encodes an AndroidManifest.xml or other predecoded APK XMLs.

ArgumentDescription
XMLXML file
encode_xml "$TMP/AndroidManifest.xml"

patch_apkโ€‹

Supports: _addon _zip

Injects a folder into an APK with optional signing/zipaligning.

ArgumentDescription
FOLDERFolder to inject
APKAPK file
OPTsign, zipalign (optional)
patch_apk "FOLDER" SystemUI.apk sign
patch_apk "FOLDER" SystemUI.apk zipalign

make_overlayโ€‹

Supports: _addon _zip

Compiles an overlay for Android 9+.

ArgumentDescription
PRIPriority level
PKGTarget package
RESResource folder
OUTOutput APK path
make_overlay 1 com.android.systemui "FOLDER" "/system/vendor/overlay/test.apk"
note

All contents of the folder are merged into the root of the overlay. For example, the res folder should exist within the specified directory (FOLDER\res).

warning

Cannot include images due to apktool limitations.