{"id":46315329,"url":"https://github.com/caverav/flutterdec","last_synced_at":"2026-03-04T14:04:52.121Z","repository":{"id":339651891,"uuid":"1158858809","full_name":"caverav/flutterdec","owner":"caverav","description":"CLI tool that decompiles Flutter Android AOT (libapp.so) into Dart-like pseudocode, supporting obfuscated builds.","archived":false,"fork":false,"pushed_at":"2026-03-01T00:20:37.000Z","size":814,"stargazers_count":6,"open_issues_count":2,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-01T03:46:30.852Z","etag":null,"topics":["decompiler","flutter","reverse-engineering"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/caverav.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2026-02-16T02:17:23.000Z","updated_at":"2026-03-01T00:20:40.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/caverav/flutterdec","commit_stats":null,"previous_names":["caverav/flutterdec"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/caverav/flutterdec","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caverav%2Fflutterdec","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caverav%2Fflutterdec/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caverav%2Fflutterdec/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caverav%2Fflutterdec/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/caverav","download_url":"https://codeload.github.com/caverav/flutterdec/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/caverav%2Fflutterdec/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30083017,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-04T13:22:36.021Z","status":"ssl_error","status_checked_at":"2026-03-04T13:20:45.750Z","response_time":59,"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":["decompiler","flutter","reverse-engineering"],"created_at":"2026-03-04T14:04:51.369Z","updated_at":"2026-03-04T14:04:52.104Z","avatar_url":"https://github.com/caverav.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# flutterdec\n\n[![CI](https://github.com/caverav/flutterdec/actions/workflows/ci.yml/badge.svg)](https://github.com/caverav/flutterdec/actions/workflows/ci.yml)\n[![Release](https://github.com/caverav/flutterdec/actions/workflows/release.yml/badge.svg)](https://github.com/caverav/flutterdec/actions/workflows/release.yml)\n\n`flutterdec` is a static Flutter AOT decompiler research tool for Android ARM64 binaries.\n\nIt takes an APK (or `libapp.so`) and emits readable pseudo-Dart plus optional IR/ASM artifacts.\n\n## North Star\n\nRecover readable behavior from Flutter AOT ARM64 binaries with enough semantic structure that reverse engineering decisions can be made from pseudocode and reports.\n\n### Primary Goals\n\n- robust semantic extraction from snapshots and metadata (libraries, classes, functions, selectors, pool semantics)\n- stable reverse-engineering-oriented pseudocode output for Android ARM64 release builds\n- version-aware adapter behavior that can be updated without rewriting core/decompiler logic\n\n### Non-Goals (Current Scope)\n\n- perfect source reconstruction of original Dart code\n- broad multi-arch support in the same maturity level (x86, iOS, JIT modes)\n- dynamic runtime emulation as the default analysis path\n\n## Who This Is For\n\n- reverse engineers and security researchers\n- Flutter internals researchers\n- developers comparing stripped/unstripped engine builds\n\n## Quick Start\n\n1. Run with `nix run` (recommended, no install):\n\n```bash\nnix run github:caverav/flutterdec -- --help\nnix run github:caverav/flutterdec -- info ./sample.apk --json\n```\n\nFrom this repository checkout:\n\n```bash\nnix run . -- --help\n```\n\n2. Install release binary (`v0.1.0-alpha.1`):\n\nLinux x64:\n\n```bash\ncurl -fLO https://github.com/caverav/flutterdec/releases/download/v0.1.0-alpha.1/flutterdec-v0.1.0-alpha.1-Linux-X64.tar.gz\ntar -xzf flutterdec-v0.1.0-alpha.1-Linux-X64.tar.gz\nsudo install -m 0755 flutterdec /usr/local/bin/flutterdec\nflutterdec --help\n```\n\nmacOS arm64:\n\n```bash\ncurl -fLO https://github.com/caverav/flutterdec/releases/download/v0.1.0-alpha.1/flutterdec-v0.1.0-alpha.1-macOS-ARM64.tar.gz\ntar -xzf flutterdec-v0.1.0-alpha.1-macOS-ARM64.tar.gz\nsudo install -m 0755 flutterdec /usr/local/bin/flutterdec\nflutterdec --help\n```\n\nOther platforms and future tags:\n\n[Releases page](https://github.com/caverav/flutterdec/releases)\n\n3. Other options:\n\nInstall into user Cargo bin (requires Nix with flakes enabled):\n\n```bash\nnix develop -c cargo install --path crates/flutterdec-cli\n~/.cargo/bin/flutterdec --help\n```\n\nRun from source without installing:\n\n```bash\nnix develop -c cargo run -p flutterdec-cli -- info ./sample.apk --json\n```\n\nBuild local release binary:\n\n```bash\nnix develop -c cargo build -p flutterdec-cli --release\n./target/release/flutterdec --help\n```\n\n## Typical Workflow\n\n1. Inspect target:\n\n```bash\nflutterdec info ./sample.apk --json\n```\n\n`info` now includes detected app package candidates (`app_package_counts_top`) when adapter metadata is available.\n\n2. Install adapter for the detected Dart hash:\n\n```bash\nflutterdec adapter install --dart-hash \u003cHASH\u003e\n```\n\n3. Decompile:\n\n```bash\nflutterdec decompile ./sample.apk -o ./out\n```\n\nBy default, `decompile` focuses app reversing (`--function-scope app-unknown`) and excludes known Flutter/Dart framework internals.\n\nTo include all functions (app + Flutter + Dart/runtime):\n\n```bash\nflutterdec decompile ./sample.apk -o ./out --function-scope all\n```\n\nTo focus only specific Dart packages (repeatable):\n\n```bash\nflutterdec decompile ./sample.apk -o ./out \\\n  --function-scope app-unknown \\\n  --app-package my_app\n```\n\nIf package names are unknown, inspect `report.json` at `function_scope.app_package_counts_top`.\nWhen `--app-package` is not provided, capped prioritization also applies manifest-derived package hints (`function_scope.priority_package_hints`) to favor app-owned code (including normalized variants like `localsend_app` and `localsend` when applicable).\n\nTo target a single function for developer-focused decompile/disassembly:\n\n```bash\nflutterdec decompile ./sample.apk -o ./out \\\n  --target va:0x613468 \\\n  --emit-asm\n```\n\n`--target` accepts `id:\u003cN\u003e`, `va:0x\u003cADDR\u003e`, `0x\u003cADDR\u003e`, or `\u003cN\u003e` (auto id/address match).\nIf `\u003cN\u003e` is ambiguous, `flutterdec` asks for explicit `id:` or `va:`. Selection details are emitted in `report.json.target_selection`.\n\n4. Optional: improve call names with stripped/unstripped engine pair:\n\n```bash\nflutterdec map-symbols \\\n  --stripped ./libflutter.stripped.so \\\n  --unstripped ./libflutter.unstripped.so \\\n  -o ./out/symbol-map\n\nflutterdec decompile ./sample.apk -o ./out \\\n  --extra-symbol-map-targets ./out/symbol-map/symbol_target_summary.json \\\n  --extra-symbol-elf ./libflutter.unstripped.so\n```\n\n5. Optional: compare two builds by recovered function signatures:\n\n```bash\nflutterdec diff --old ./old.apk --new ./new.apk -o ./out-diff --json\n```\n\n`diff_report.json` includes added/removed/common function counts plus `added_packages_top` and `removed_packages_top` summaries.\n\n6. Optional: emit import scripts for RE tools:\n\n```bash\nflutterdec decompile ./sample.apk -o ./out \\\n  --emit-ghidra-script \\\n  --emit-ida-script\n```\n\n## Analysis Profiles\n\n`decompile` exposes analysis-engine profiles so you can trade detail for speed.\n\nDefault profile:\n\n- `balanced` (recommended)\n\nAvailable profiles:\n\n- `balanced`: full semantic naming/hints/reporting\n- `light`: lower-overhead analysis for faster large-scale runs\n\nExample:\n\n```bash\nflutterdec decompile ./sample.apk -o ./out --analysis-profile light\n```\n\nAdapter backend selection:\n\n- `--adapter-backend auto` (default): try Blutter backend if configured, otherwise fallback to internal adapter\n- `--adapter-backend internal`: force internal snapshot-string adapter\n- `--adapter-backend blutter`: require Blutter backend (fail if unavailable)\n- `--require-snapshot-hash-match`: fail early when adapter-reported snapshot hash does not match loader snapshot hash\n\nBlutter backend environment knobs:\n\n- `FLUTTERDEC_BLUTTER_CMD`: full command to launch Blutter (for example `python3 /path/to/blutter.py`)\n- `FLUTTERDEC_BLUTTER_PY`: path to `blutter.py` (uses current Python interpreter)\n\nNix integration:\n\n- `nix develop` now provides `flutterdec-blutter` and auto-exports `FLUTTERDEC_BLUTTER_CMD` to that wrapper.\n- You can also run the wrapper directly via `nix run .#blutter-bridge -- --help`.\n\nYou can explicitly enable/disable individual engine toggles:\n\n- `--with-canonical-model-symbols` / `--no-canonical-model-symbols`\n- `--with-pool-value-hints` / `--no-pool-value-hints`\n- `--with-pool-semantic-hints` / `--no-pool-semantic-hints`\n- `--with-semantic-reporting` / `--no-semantic-reporting`\n- `--with-bootflow-category-seeds` / `--no-bootflow-category-seeds`\n\n## Output\n\nMain outputs under `-o \u003cOUT_DIR\u003e`:\n\n- `pseudocode/*.dartpseudo`\n- `quality.json`\n- `report.json`\n- `diff_report.json` (if `flutterdec diff`)\n- `asm/*.s` (if `--emit-asm`)\n- opcode-prefixed asm lines (if `--emit-asm --emit-asm-opcodes`)\n- `ghidra_apply_symbols.py` (if `--emit-ghidra-script`; applies symbol names and pool-load comments)\n- `ida_apply_symbols.py` (if `--emit-ida-script`; applies symbol names and pool-load comments in IDA)\n- `ir/*.json` (if `--emit-ir`)\n\n`report.json` also includes a `compatibility` section for schema/hash/manifest alignment diagnostics.\n\n## Documentation\n\n- User guide: [docs/user-guide.md](docs/user-guide.md)\n- CLI reference: [docs/cli-reference.md](docs/cli-reference.md)\n- Development guide: [docs/development.md](docs/development.md)\n- Architecture: [docs/architecture.md](docs/architecture.md)\n- Internals walkthrough: [docs/how-it-works.md](docs/how-it-works.md)\n- Research decisions: [docs/research-decisions.md](docs/research-decisions.md)\n- Contributing: [CONTRIBUTING.md](CONTRIBUTING.md)\n- Context and project history: [context.md](context.md)\n\n## Issue Types\n\n- Bug report: [new bug issue](https://github.com/caverav/flutterdec/issues/new?template=bug_report.md)\n- Feature request: [new feature issue](https://github.com/caverav/flutterdec/issues/new?template=feature_request.md)\n- Research finding: [new research issue](https://github.com/caverav/flutterdec/issues/new?template=research_finding.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcaverav%2Fflutterdec","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcaverav%2Fflutterdec","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcaverav%2Fflutterdec/lists"}