{"id":29666618,"url":"https://github.com/androguard/axml","last_synced_at":"2026-05-18T07:33:11.487Z","repository":{"id":305092654,"uuid":"953673713","full_name":"androguard/axml","owner":"androguard","description":"Android binary XML parser in Python","archived":false,"fork":false,"pushed_at":"2025-09-24T18:42:41.000Z","size":6011,"stargazers_count":16,"open_issues_count":3,"forks_count":3,"subscribers_count":5,"default_branch":"main","last_synced_at":"2026-04-24T17:39:39.775Z","etag":null,"topics":["android","axml","binary","parser","xml"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/androguard.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["androguard"]}},"created_at":"2025-03-23T21:59:36.000Z","updated_at":"2026-04-08T01:00:09.000Z","dependencies_parsed_at":"2025-07-18T09:55:39.409Z","dependency_job_id":"b25dcf3c-7b38-4b77-93de-2e91f8c6d13e","html_url":"https://github.com/androguard/axml","commit_stats":null,"previous_names":["androguard/axml"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/androguard/axml","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/androguard%2Faxml","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/androguard%2Faxml/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/androguard%2Faxml/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/androguard%2Faxml/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/androguard","download_url":"https://codeload.github.com/androguard/axml/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/androguard%2Faxml/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33169260,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-18T05:43:36.989Z","status":"ssl_error","status_checked_at":"2026-05-18T05:43:19.133Z","response_time":71,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","axml","binary","parser","xml"],"created_at":"2025-07-22T15:38:48.981Z","updated_at":"2026-05-18T07:33:11.481Z","avatar_url":"https://github.com/androguard.png","language":"Python","funding_links":["https://github.com/sponsors/androguard"],"categories":[],"sub_categories":[],"readme":"\n\u003cp align=\"center\"\u003e\u003cimg width=\"120\" src=\"./.github/logo.png\"\u003e\u003c/p\u003e\n\u003ch2 align=\"center\"\u003eAXML\u003c/h2\u003e\n\n# AXML/ARSC: The Rosetta Stone for Android's Binary XML\n\n\u003cdiv align=\"center\"\u003e\n\n![Powered](https://img.shields.io/badge/androguard-green?style=for-the-badge\u0026label=Powered%20by\u0026link=https%3A%2F%2Fgithub.com%2Fandroguard)\n![Sponsor](https://img.shields.io/badge/sponsor-nlnet-blue?style=for-the-badge\u0026link=https%3A%2F%2Fnlnet.nl%2F)\n![PYPY](https://img.shields.io/badge/PYPI-AXML-violet?style=for-the-badge\u0026link=https%3A%2F%2Fpypi.org%2Fproject%2Faxml%2F)\n\n\n\u003c/div\u003e\n\nAndroid doesn't speak in plain text XML. To save space and speed up parsing,\nit uses a compressed, obfuscated binary format (AXML) for its manifests and \na complex table (ARSC) for its resources. axml is your translator.\n\nThis is a standalone, dependency-free, native Python library built to decode\nthe secrets of Android's binary XML and resource files. It is a \nbattle-hardened pillar of the new Androguard Ecosystem, providing the critical\n ability to turn machine-optimized formats back into human-readable intelligence.\n\nThis is a library for handling the `AXML` file format. `AXML` is the informal\ncommon name for the compiled binary `XML` data format used in Android app files.\nThe Android Open Source Project does not seem to have named the format, other\nthan referring to is as `binary XML` or `compiled XML`.So `AXML` stands for\nAndroid XML. The file format is based on compiling XML source into a binary\nformat based on [protobuf](). There are a number of different Android XML file\ntypes that are compiled to AXML, these are generically known as [Android\nResources](https://developer.android.com/guide/topics/resources/available-resources).\n\nAll of these files are included in the APK's ZIP package with the file extension\n`.xml` even though they are actually `AXML` and not `XML`.\n\nSome specific data files, like String Resources and Style Resources, are instead\ncompiled into a single file `resources.arsc` in its own data format, known as\nASRC.  AXML files often refer to values that are in `resources.arsc`.\n\nThe entry point for an app is the \"[app\nmanifest](https://developer.android.com/guide/topics/manifest/manifest-element)\"\ndefines the essential data points that every app must have, like Package Name\nand Version Code, and includes lots of other metadata that describe the\napp. Every Android app file (APK) must include\n[`AndroidManifest.xml`](https://developer.android.com/guide/topics/manifest/manifest-intro),\nwhich in the APK is the compiled binary AXML format, not XML, despite the file\nextension.  The source code files for the binary app manifest file are also\ncalled `AndroidManifest.xml`, but they are actually XML.  There can be\n[multiple](https://developer.android.com/build/manage-manifests) source files,\nbut there is only ever one single compiled binary `AndroidManifest.xml` that is\nvalid in the APK.\n\nhttps://developer.android.com/guide/topics/manifest/manifest-intro#reference\n\n\n## Installation\n\nIf you would like to install it locally, please create a new venv to use it directly, and then:\n\n```\n$ git clone https://github.com/androguard/axml.git\n$ pip install -e .\n```\n\nor directly via pypi:\n\n```\n$ pip install axml\n```\n\n### Usage\n\nTwo new commands will be exported in your current environnement: `axml` and `arsc`, that will allow to read and display\nthe corresponding files.\n\n```\n$ axml -i AndroidManifest.xml\n$ arsc -i resources.arsc\n```\n\n### API\n\nThe most easy way to use this project is probably directly via using the API:\n\n```\n\u003e\u003e\u003e from axml.axml import AXMLPrinter\n\u003e\u003e\u003e from axml.arsc import ARSCPrinter\n\u003e\u003e\u003e AXMLPrinter(open(\"AndroidManifest.xml\", \"rb\").read())\n\u003e\u003e\u003e obj\n\u003caxml.axml.printer.AXMLPrinter object at 0x76b5a34b0550\u003e\n\u003e\u003e\u003e obj.package\n'org.t0t0.androguard.TC'\n\u003e\u003e\u003e obj.androidversion\n{'Code': '1', 'Name': '1.0'}\n\n\u003e\u003e\u003e obj = ARSCPrinter(open(\"test.arsc\", \"rb\").read())\n\u003e\u003e\u003e obj\n\u003caxml.arsc.printer.ARSCPrinter object at 0x76b5a34b1310\u003e\n\u003e\u003e\u003e obj.get_xml()\nb'\u003cresources\u003e\\n\u003cpublic type=\"drawable\" name=\"icon\" id=\"0x7f020000\"/\u003e\\n\u003cpublic type=\"drawable\" name=\"icon\" id=\"0x7f020000\"/\u003e\\n\u003cpublic type=\"drawable\" name=\"icon\" id=\"0x7f020000\"/\u003e\\n\u003cpublic type=\"layout\" name=\"main\" id=\"0x7f030000\"/\u003e\\n\u003cpublic type=\"string\" name=\"hello\" id=\"0x7f040000\"/\u003e\\n\u003cpublic type=\"string\" name=\"app_name\" id=\"0x7f040001\"/\u003e\\n\u003c/resources\u003e\\n'\n```\n\n## AXML binary format\n\nSome references about the binary AXML format:\n\n* [_aapt2_](https://developer.android.com/tools/aapt2) compiles XML to protobuf-based AXML\n* [_aapt2_ source code](https://android.googlesource.com/platform/frameworks/base/+/master/tools/aapt2)\n* [_aapt_ source code](https://android.googlesource.com/platform/frameworks/base/+/master/tools/aapt)\n* The binary format for `AndroidManifest.xml` is defined in [`ApkInfo.proto`](https://android.googlesource.com/platform/frameworks/base/+/refs/heads/main/tools/aapt2/ApkInfo.proto).\n\n![Android binary XML](https://raw.githubusercontent.com/senswrong/AndroidBinaryXml/main/AndroidBinaryXml.png)\n\n\u003c!-- back up URL in case the one above goes away\n![Android binary XML](https://github.com/user-attachments/assets/6439a13a-5a50-4f32-b106-c70c9fb9acf1)\n--\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandroguard%2Faxml","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandroguard%2Faxml","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandroguard%2Faxml/lists"}