<p align="center">
<img src="https://img.shields.io/badge/Rust-000000?style=for-the-badge&logo=rust&logoColor=white" />
<img src="https://img.shields.io/badge/IL2CPP-v16--v39-blueviolet?style=for-the-badge" />
<img src="https://img.shields.io/badge/License-MIT-green?style=for-the-badge" />
</p>
<h1 align="center">๐ก๏ธ Rodroid Il2CppDumper V4</h1>
<p align="center">
<b>A blazing-fast, cross-platform IL2CPP binary dumper written in Rust.</b><br/>
Full rewrite from the original C# <a href="https://github.com/Perfare/Il2CppDumper">Il2CppDumper</a> with significant performance improvements, modern CLI UI, and advanced features.
</p>
<p align="center">
<a href="https://t.me/+WmudnO0-xoNhMDQ8">๐ข Telegram Channel</a> ยท
<a href="https://t.me/+QylrYL1GNsJiYjc0">๐ฌ Telegram Group</a> ยท
<b>Dev:</b> <a href="https://t.me/rodroidmods"><code>@rodroidmods</code></a>
</p>
---
## ๐ Feature Comparison โ Rust vs C# vs Python
| **dump.cs generation** | โ ๏ธ Basic (no properties) | โ
Full | โ
Full |
| **DummyDLL generation** | โ No | โ
Yes | โ
Yes (parallel) |
| **il2cpp.h struct gen** | โ ๏ธ Basic | โ
Full | โ
Full |
| **script.json** | โ
Yes | โ
Yes | โ
Yes |
| **stringliteral.json** | โ
Yes | โ
Yes | โ
Yes |
| **Split Dump Per Type (DiffableCS)** | โ No | โ No | โ
**Yes (parallel)** |
| **Variable-width indices (v39/Unity 6)** | โ No | โ No | โ
**Yes** |
| **Auto-XOR Metadata Decryption** | โ No | โ No | โ
**Yes** |
| **Latest Unity Formats (v104, v106)** | โ No | โ No | โ
**Yes** |
| **Assembly name in dump.cs** | โ No | โ No | โ
**Yes** |
| **Unity version detection** | โ No | โ No | โ
**Auto-detect** |
| **Inline Disassembly (ARM64/ARM32/x86/x64)** | โ No | โ No | โ
**Yes** |
| **Control Flow Graph (CFG) Analysis** | โ No | โ No | โ
**Yes** |
| **Metadata Annotations (strings, types, vtable)** | โ No | โ No | โ
**Yes** |
| **Semantic Variable Tracking** | โ No | โ No | โ
**Yes** |
| **Fat Mach-O (Universal)** | โ No | โ
Yes | โ
Yes |
| **WASM (WebGL)** | โ
Yes | โ
Yes | โ
Yes |
| **Dump file support** | โ No | โ
Yes | โ
Yes (+ ELF reload) |
| **v27+ ImageBase fix** | โ No | โ
Yes | โ
Yes |
| **Parallel I/O (`rayon`)** | โ No | โ No | โ
**Yes** |
| **Auto-numbered output dirs** | โ No | โ No | โ
**Dump0/, Dump1/...** |
| **Modern CLI UI (spinners, colors, prompts)** | โ No | โ No | โ
**Yes** |
| **Cross-platform binary** | โ ๏ธ Needs Python | โ ๏ธ Needs .NET | โ
**Standalone** |
| **C++ Scaffold (il2cpp-functions.h)** | โ No | โ No | โ
**Yes** |
| **C++ Name Mangling (Itanium ABI)** | โ No | โ No | โ
**Yes** |
| **Unity Header Auto-Detection** | โ No | โ
Yes | โ
**Yes (version-matched)** |
| **cpp_project/ Scaffolding** | โ No | โ
Yes | โ
**Yes** |
| **Topological Sort (type ordering)** | โ No | โ No | โ
**Yes** |
| **Type Group Classification** | โ No | โ No | โ
**Yes** |
| **Enhanced IDA Metadata** | โ No | โ No | โ
**Yes** |
| **ELF Section Header Symbol Fallback** | โ No | โ
Yes | โ
**Yes** |
| **GUI** | โ No | โ
WinForms | โ
**Jetpack Compose + Tauri** |
| **Embeddable as library** | โ No | โ No | โ
**Rust crate / JNI** |
### โก Performance
| Metadata loading | ~3.7s | ~2s | **~0.5s** |
| Binary loading | ~5.2s | ~3s | **~0.8s** |
| Search & Init | ~5.4s | ~2s | **~0.3s** |
| dump.cs | ~14s | ~5s | **~2s** |
| Struct generation | ~6.4s | ~5s | **~3.5s** |
| DummyDLL | โ N/A | ~3s | **~1.5s** |
| **Total** | **~35s** | **~20s** | **~5โ8s** |
> **4ร faster than Python, 2.4ร faster than C#** โ on the same binary.
---
## โจ Features
### Core Dumping
- **dump.cs** โ Full C# class/method/field/property decompilation with RVA/VA/Offset and assembly names
- **Inline Disassembly** โ Optional per-method native assembly embedded directly in dump.cs
- **DiffableCs** โ Splits classes into individual `.cs` files by namespace, parallelized with `rayon`
- **script.json** โ Method addresses/signatures for IDA/Ghidra scripting
- **il2cpp.h** โ C struct definitions for native analysis with topological type ordering
- **stringliteral.json** โ All string literal values and indices
- **DummyDLL** โ Reconstructed .NET assemblies for dnSpy/ILSpy (parallelized)
### C++ Headers & Scaffolding
- **il2cpp-functions.h** โ C++ scaffold with function pointer typedefs for hooking
- **Itanium ABI Name Mangling** โ Correct C++ mangled names for all IL2CPP types
- **Unity Header Auto-Detection** โ Version-matched `il2cpp-types.h` and `il2cpp-api.h` from embedded header database
- **cpp_project/** โ Ready-to-compile C++ project scaffold with includes and CMake structure
- **Topological Sort** โ Types emitted in dependency order; circular dependencies detected with fallback
- **Type Group Classification** โ Types categorized into forward declarations, method types, generic types, usage types
- **Compiler Layout** โ GCC (`__attribute__`) or MSVC (`__declspec`) layout attributes
- **Enhanced IDA Metadata** โ Extra type info annotations for IDA Pro scripts
### Disassembly Engine
- **Multi-Architecture** โ ARM64 (`yaxpeax-arm`), ARM32, x86/x64 (`iced-x86`)
- **Control Flow Graph (CFG)** โ Basic block detection, branch targets, loop back-edges, `if (condition)` reconstruction
- **Metadata Annotations** โ String literals, type info, method/field references, vtable resolution via `ADRP+LDR` patterns
- **Semantic Variable Tracking** โ Maps registers to parameter names (`X0` โ `this`, `X1` โ `arg0`)
- **Configurable** โ Toggle hex bytes, field names, annotations, CFG independently
### Supported Platforms
| Android | ELF32 / ELF64 | โ
|
| iOS / macOS | Mach-O / Fat Mach-O | โ
|
| Windows | PE32 / PE64 | โ
|
| Nintendo Switch | NSO | โ
|
| WebGL | WASM | โ
|
### IL2CPP Versions
- **v16 โ v39** (Unity 5.3 โ Unity 6)
- Variable-width indices for v39/Unity 6
- Latest undocumented formats: `v104`, `v106`
- Auto XOR metadata decryption (1-byte, 4-byte, 8-byte, rolling, position-dependent, header-only)
- Manual version override via config
### Search Strategies
- **SectionHelper** โ Format-aware section scanning
- **Symbol Search** โ ELF/Mach-O symbol table lookup
- **ARM32 Search** โ Dedicated binary pattern matching
- **\_\_mod\_init\_func** โ Mach-O initializer analysis
- **Manual mode** โ Enter addresses as fallback
---
## ๐ฆ Installation
### From Source
```bash
git clone https://github.com/rodroidmods/il2cpp-dumper-rs.git
cd il2cpp-dumper-rs/il2cpp_dumper
cargo build --release
```
The binary will be at `target/release/il2cpp_dumper` (`.exe` on Windows).
### Cross-Compilation
```bash
# Linux
cargo build --release --target x86_64-unknown-linux-gnu
# macOS
cargo build --release --target aarch64-apple-darwin
# Android (via cross)
cross build --release --target aarch64-linux-android
```
---
## ๐ง Usage
```bash
il2cpp_dumper <il2cpp-binary> <global-metadata.dat> [output-dir]
```
### Examples
```bash
il2cpp_dumper libil2cpp.so global-metadata.dat
il2cpp_dumper GameAssembly.dll global-metadata.dat ./output
il2cpp_dumper UnityFramework global-metadata.dat
```
### Example Output
```
Rodroid Il2CppDumper
โฆโฆ โโโโโโโโโ โโฆโโฆ โฆโโฆโโโโโโโโฆโโ
โโ โ โโโ โ โโ โโโ โโโโโ โโโโฃ โ โฆโ
โฉโฉโโโ โโโโฉ โโฉโโโโโฉ โฉโฉ โโโโฉโโ
Version v0.4.0
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ Output .\Dump0
โโโ Binary Analysis โโโโโโโโโโโโโโโโโโโ
โ Binary loaded: libil2cpp.so (52.43 MB)
Unity Version: 2022.3.62f2
โ Metadata loaded: global-metadata.dat (10.88 MB)
Metadata Version: 31
Type Definitions: 13815
Method Definitions: 93772
โโโ Format Detection โโโโโโโโโโโโโโโโโโ
๐ Detected ELF64 format
IL2CPP Version: 31
CodeRegistration: 0x44e5ff8
MetadataRegistration: 0x465a328
โโโ Output Generation โโโโโโโโโโโโโโโโโ
โ dump.cs generated
โ script.json, il2cpp.h, stringliteral.json generated
โ Dummy DLL files generated
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โจ All tasks completed successfully!
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ Output Directory: .\Dump0
๐ฆ Generated Files: dump.cs, script.json, il2cpp.h, stringliteral.json, DummyDll/*.dll
๐ Elapsed: 8.35s
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
```
---
## โ๏ธ Configuration
Create a `config.json` in the working directory (or use `--config`):
```json
{
"ForceIl2CppVersion": false,
"ForceVersion": 29.0,
"ForceDump": false,
"NoRedirectedPointer": false,
"GenerateStruct": true,
"GenerateDummyDll": true,
"DummyDllAddToken": true,
"dumpDisassembly": false,
"dumpDisassemblyHexBytes": true,
"dumpDisassemblyFieldNames": true,
"dumpDisassemblyAnnotations": true,
"dumpDisassemblyCfg": true,
"maxDisassemblyInstructions": 512,
"generateCppScaffold": true,
"mangleNames": true,
"enhancedIdaMetadata": true,
"generateUnityHeaders": true,
"compilerLayout": "GCC",
"useTopologicalSort": true
}
```
---
## ๐๏ธ Architecture
```
il2cpp_dumper/src/
โโโ main.rs # CLI, format detection, orchestration
โโโ config.rs # Configuration handling
โโโ formats/ # Binary format parsers
โ โโโ elf.rs # ELF32/64 (Android, Linux)
โ โโโ pe.rs # PE32/64 (Windows)
โ โโโ macho.rs # Mach-O + Fat Mach-O (iOS, macOS)
โ โโโ nso.rs # NSO (Nintendo Switch)
โ โโโ wasm.rs # WebAssembly (WebGL)
โโโ il2cpp/ # IL2CPP structures and metadata
โ โโโ base.rs # Il2Cpp main struct
โ โโโ metadata.rs # Metadata parser
โ โโโ structures.rs # IL2CPP type definitions
โโโ search/ # Registration search algorithms
โ โโโ section_helper.rs
โโโ executor/ # IL2CPP type resolution engine
โโโ disassembler/ # Multi-arch disassembly engine
โ โโโ mod.rs # CFG analysis, annotations, formatting
โ โโโ arm.rs # ARM64/ARM32 decoder (yaxpeax)
โ โโโ x86.rs # x86/x64 decoder (iced-x86)
โโโ output/ # Output generators
โโโ decompiler.rs # dump.cs + inline disassembly
โโโ struct_generator.rs # script.json, il2cpp.h, type classification
โโโ dummy_assembly_generator.rs # DummyDLL (parallel)
โโโ cpp_scaffolding.rs # il2cpp-functions.h generation
โโโ cpp_ast.rs # C++ AST emission with group annotations
โโโ cpp_type_model.rs # C++ type model from IL2CPP types
โโโ cpp_type_dependency_graph.rs # Topological sort + cycle detection
โโโ name_mangler.rs # Itanium ABI C++ name mangling
โโโ header_manager.rs # Unity header version matching
โโโ unity_version.rs # Unity version parsing & ranges
```
---
## ๐ License
MIT
---
## ๐ Credits
- [Perfare/Il2CppDumper](https://github.com/Perfare/Il2CppDumper) โ Original C# implementation
- [SamboyCoding/Cpp2IL](https://github.com/SamboyCoding/Cpp2IL) โ Advanced C# IL2CPP analysis tool
- [springmusk026/Il2CppDumper-Python](https://github.com/springmusk026/Il2CppDumper-Python) โ Python port
- [LukeFZ/Il2CppInspectorRedux](https://github.com/LukeFZ/Il2CppInspectorRedux) โ Thanks for the code i used in v4 of my il2cppdumper, but its more faster since the logic its on rust and not C#
- [dotnetdll](https://crates.io/crates/dotnetdll) โ .NET DLL generation crate
- [rayon](https://crates.io/crates/rayon) โ Parallel processing
- [console-rs](https://github.com/console-rs) โ Terminal styling ecosystem (`console`, `indicatif`, `dialoguer`)
---
## ๐ฌ Community
| ๐ข **Telegram Channel** | [Join Channel](https://t.me/+WmudnO0-xoNhMDQ8) |
| ๐ฌ **Telegram Group** | [Join Group](https://t.me/+QylrYL1GNsJiYjc0) |
| ๐ค **Developer** | [`@rodroidmods`](https://t.me/rodroidmods) |
---
> **โ ๏ธ Disclaimer**: This tool is for educational and research purposes only. Respect game developers' rights and terms of service.