An Advanced Axml Printer available with proper xml style/format feature
A tool for printing out Android binary XML files (It can be Android Manifest or other resources XML files) into normal raw AXML text. It is inspired by Android4ME's axmlprinter library.
There are several changes made to the code, and multiple bugs have been fixed. The following changes have been made in this AXMLPrinter library:
- Added support for translating enum or flags based attributes (Customized function)
- Fixed decoding some UTF-8.
- Extraction of attribute name from id
- Extraction of flag and enum values according to android resource
- Fixed close tag error
- Fixed handling unknown attributes
- Fixed indentation/tab error
- Improved speed in xml decompilation
- Extraction of Attribute name according to resource id
- Id2Name (Reading axml file according to the resource id name)
- Extraction of manifest permissions short description (Customized function)
- Reading pseudo-encrypted xml files
Decompile a binary XML file from a file path:
AXMLPrinter axmlPrinter = new AXMLPrinter();
String xml = axmlPrinter.readFromFile("/path/to/binary/AndroidManifest.xml");Directly extract and decompile AndroidManifest.xml from an APK file, with automatic pseudo-encryption bypass:
AXMLPrinter axmlPrinter = new AXMLPrinter();
String xml = axmlPrinter.readFromApk("/path/to/app.apk");You can enable advanced features like attribute value translation (e.g., converting hex to flag names) and permission descriptions:
AXMLPrinter axmlPrinter = new AXMLPrinter();
axmlPrinter.setAttrValueTranslation(true); // Translate enum/flag attributes
axmlPrinter.setExtractPermissionDescription(true); // Add permission comments in manifest
axmlPrinter.setEnableID2Name(true); // Enable ID to name resolution (requires resources.arsc)
String xml = axmlPrinter.readFromFile(path);To resolve custom resource IDs to names, place the resources.arsc file in the same directory as your binary XML file, or load it manually:
InputStream arscStream = new FileInputStream("resources.arsc");
axmlPrinter.loadCustomResources(arscStream);I injected my library in MT Manager Mod You can download the apk file from my Telegram Channel. Download Now
- Apache License V2.0 http://www.apache.org/licenses/LICENSE-2.0
- Fork repository
- Make changes
- Ensure tests pass (or hopefully adding tests!)
- Submit pull request/issue
- XML Pull Parsing: http://www.xmlpull.org/
- AXMLPrinter(Android4ME)

