[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M78HVSARM9TJWSVJSG93KRTA":3,"skill-same:01M78HVSARM9TJWSVJSG93KRTA":49},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":18,"linkOnly":19,"markdownContent":20,"markdownBody":21,"frontMatter":22,"refName":29,"commitSha":30,"skillDirectory":31,"forksCount":13,"repositoryHtmlUrl":32,"repositoryHomepageUrl":6,"ownerHtmlUrl":33,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":34,"install":35,"resources":48},"01M78HVSARM9TJWSVJSG93KRTA","il2cpp",null,"Unity IL2CPP game reversing — Il2CppDumper metadata recovery, global-metadata.dat decryption, IDA\u002FGhidra symbol restore via generated scripts, Frida method hooking, IAP\u002Flicense bypass, and zygisk-il2cpp-dumper for obfuscated metadata.","dnzengou\u002Fevo-decepticon","dnzengou","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F7807581?v=4","01M75KKJA3F5ZP7CA10MB2AEXC","01M78GP0FED2V1CDPB1N6G0CTH",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fmobile\u002Fandroid\u002Fil2cpp\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: il2cpp\ndescription: Unity IL2CPP game reversing — Il2CppDumper metadata recovery, global-metadata.dat decryption, IDA\u002FGhidra symbol restore via generated scripts, Frida method hooking, IAP\u002Flicense bypass, and zygisk-il2cpp-dumper for obfuscated metadata.\nallowed-tools: Bash Read Write\nmetadata:\n  subdomain: mobile\n  when_to_use: \"unity il2cpp libil2cpp.so global-metadata.dat il2cppdumper il2cppinspector mono game reversing anti-cheat license iap inapp purchase ghidra ida symbol restore zygisk\"\n  tags: unity, il2cpp, game, reverse-engineering, il2cppdumper, global-metadata, ghidra, frida, iap, anti-cheat\n  mitre_attack: T1635, T1406, T1407\n---\n\n# Unity IL2CPP Game Reversing Playbook\n\n> Unity IL2CPP compiles C# to C++ then to native `libil2cpp.so`. The\n> managed bytecode is stripped — `jadx` and `apktool` expose only the\n> thin Java bootstrap and reveal nothing of game logic. This playbook\n> recovers readable symbols and hooks runtime methods for license\u002FIAP\n> bypass and vulnerability assessment.\n\n## Prerequisites\n\n- APK obtained (see `mobile\u002Fandroid\u002FSKILL.md` for pull methods).\n- **Il2CppDumper** (Windows .NET or mono CLI):\n  https:\u002F\u002Fgithub.com\u002FPerfare\u002FIl2CppDumper\n- **Il2CppInspector** (alternative with plugin support):\n  https:\u002F\u002Fgithub.com\u002Fdjkaty\u002FIl2CppInspector\n- Ghidra (via MCP `ghidra` server) or IDA (host-side).\n- Frida + Objection for runtime hooking (see `mobile\u002Fandroid\u002FSKILL.md`\n  Frida setup section).\n- **zygisk-il2cpp-dumper** for runtime metadata on protected apps:\n  https:\u002F\u002Fgithub.com\u002FPerfare\u002FZygisk-Il2CppDumper\n\n## Step 1: Identify Unity IL2CPP App\n\n```bash\nunzip -o base.apk -d \u002Ftmp\u002Fapk-out\u002F\n\n# Confirm IL2CPP backend\nls \u002Ftmp\u002Fapk-out\u002Flib\u002Farm64-v8a\u002F\n# Must contain: libil2cpp.so\n\nls \u002Ftmp\u002Fapk-out\u002Fassets\u002Fbin\u002FData\u002FManaged\u002FMetadata\u002F\n# Must contain: global-metadata.dat\n\n# If only libmono.so present → Mono backend (smali\u002Fjadx works; this skill N\u002FA)\n# If libil2cpp.so present but no global-metadata.dat → encrypted\u002Fobfuscated (go to Step 5)\n\nfile \u002Ftmp\u002Fapk-out\u002Flib\u002Farm64-v8a\u002Flibil2cpp.so\n# output: ELF 64-bit LSB shared object, ARM aarch64\n```\n\n## Step 2: Recover Symbols with Il2CppDumper\n\n```bash\n# Extract libs from APK\ncp \u002Ftmp\u002Fapk-out\u002Flib\u002Farm64-v8a\u002Flibil2cpp.so \u002Ftmp\u002F\ncp \u002Ftmp\u002Fapk-out\u002Fassets\u002Fbin\u002FData\u002FManaged\u002FMetadata\u002Fglobal-metadata.dat \u002Ftmp\u002F\n\n# Run Il2CppDumper (mono CLI on Linux\u002FmacOS)\nmono Il2CppDumper.exe \u002Ftmp\u002Flibil2cpp.so \u002Ftmp\u002Fglobal-metadata.dat \u002Ftmp\u002Fdump-output\u002F\n\n# Windows .NET:\n# Il2CppDumper.exe \u003Clibil2cpp.so> \u003Cglobal-metadata.dat> \u003Coutput-dir>\n```\n\nOutput files:\n| File | Content |\n|---|---|\n| `dump.cs` | All C# class\u002Fmethod\u002Ffield definitions with offsets |\n| `script.json` | Machine-readable symbol map (used by IDA\u002FGhidra scripts) |\n| `il2cpp.h` | C-style struct definitions for IL2CPP internals |\n| `stringliteral.json` | All managed string literals with addresses |\n\n```bash\n# Quick scan of dump.cs for interesting classes\ngrep -i \"licen\\|premium\\|iap\\|purchase\\|unlock\\|cheat\\|anti\\|integrity\" \u002Ftmp\u002Fdump-output\u002Fdump.cs | head -30\n\n# Find method offsets for hooks\ngrep -A2 \"IsPremium\\|CheckLicense\\|VerifyReceipt\\|IsSubscribed\" \u002Ftmp\u002Fdump-output\u002Fdump.cs\n# Output: \u002F\u002F RVA: 0x\u003Coffset>  — this is the function RVA in libil2cpp.so\n```\n\n## Step 3: Apply Symbols in Ghidra \u002F IDA\n\n### Ghidra (via MCP ghidra server — batch mode)\n\n```\n# 1. Import libil2cpp.so into Ghidra project\n# 2. Run auto-analysis (aarch64)\n# 3. Execute the Il2CppDumper Ghidra script:\n#    Script: ghidra_with_struct.py  (from Il2CppDumper\u002Ftools\u002F)\n#    Input: script.json + il2cpp.h\n# 4. All methods now have their managed C# names\n```\n\n```bash\n# Command-line Ghidra headless analysis + script\n\"$GHIDRA_HOME\u002Fsupport\u002FanalyzeHeadless\" \u002Ftmp\u002Fghidra-project IL2CPP \\\n  -import \u002Ftmp\u002Flibil2cpp.so \\\n  -postScript ghidra_with_struct.py \u002Ftmp\u002Fdump-output\u002Fscript.json \\\n  -processor AARCH64:LE:64:v8A \\\n  -noanalysis\n```\n\n### IDA (host-side)\n\n```python\n# In IDA scripting console (Python):\n# Run ida_with_struct_py3.py from Il2CppDumper\u002Ftools\u002F\n# File → Script File → ida_with_struct_py3.py\n# Provide path to script.json when prompted\n# IDA applies all function names + struct types\n```\n\nAfter symbol restore, navigate to `IsPremiumUser`, `CheckLicense`,\n`VerifyIAP`, `IsCheatDetected`, etc. by name.\n\n## Step 4: Frida Runtime Hooking\n\n### Hook via RVA from dump.cs\n\n```javascript\n\u002F\u002F Read RVA from dump.cs comment line: \u002F\u002F RVA: 0x\u003Chex>\n\u002F\u002F Base address of libil2cpp.so changes per run; use Module.findBaseAddress\n\nvar il2cpp_base = Module.findBaseAddress(\"libil2cpp.so\");\n\n\u002F\u002F Example: hook IsPremiumUser at RVA 0x1A4F80\nvar RVA = 0x1A4F80;\nvar isPremium = il2cpp_base.add(RVA);\n\nInterceptor.attach(isPremium, {\n    onEnter: function(args) {\n        console.log(\"[+] IsPremiumUser called\");\n    },\n    onLeave: function(retval) {\n        console.log(\"[+] Original return:\", retval.toInt32());\n        retval.replace(ptr(1));  \u002F\u002F return true\n        console.log(\"[+] Replaced with: 1\");\n    }\n});\n```\n\n```bash\n# Load hook script\nfrida -U -f com.unity.targetgame -l hook-il2cpp.js --no-pause\n```\n\n### Static libil2cpp.so patch (persistent, no Frida needed)\n\n```bash\n# Patch return value of IsPremiumUser at computed file offset\npython3 - \u003C\u003C'EOF'\nimport struct\n\nRVA = 0x1A4F80\nLOAD_OFFSET = 0x0  # verify with readelf -l libil2cpp.so\n\nwith open(\"\u002Ftmp\u002Flibil2cpp.so\", \"r+b\") as f:\n    file_offset = RVA - LOAD_OFFSET\n    f.seek(file_offset)\n    # AArch64: MOV W0, #1 (0x20008052) + RET (0xC003_5FD6)\n    f.write(b\"\\x20\\x00\\x80\\x52\\xC0\\x03\\x5F\\xD6\")\nprint(f\"[+] Patched at file offset 0x{file_offset:X}\")\nEOF\n\n# Repack APK\napktool b \u002Ftmp\u002Fapk-smali\u002F -o \u002Ftmp\u002Fpatched.apk\n# Replace libs\u002Farm64-v8a\u002Flibil2cpp.so with patched version\nzip -u \u002Ftmp\u002Fpatched.apk lib\u002Farm64-v8a\u002Flibil2cpp.so\nuber-apk-signer.jar --allowResign -a \u002Ftmp\u002Fpatched.apk -o \u002Ftmp\u002F\nadb install \u002Ftmp\u002Fpatched-aligned-signed.apk\n```\n\n## Step 5: Encrypted \u002F Obfuscated global-metadata.dat\n\nSome apps (particularly heavily monetized games) encrypt or obfuscate\n`global-metadata.dat` to frustrate IL2CPP reversing.\n\n### Detect obfuscation\n\n```bash\n# Check magic bytes — valid global-metadata starts with: AF 1B B1 FA\nxxd \u002Ftmp\u002Fglobal-metadata.dat | head -2\n# If first 4 bytes ≠ AF 1B B1 FA → encrypted\u002Fcustom header\n```\n\n### Common obfuscation patterns\n\n| Pattern | Detection | Counter |\n|---|---|---|\n| XOR with static key | First 4 bytes XOR'd from AF 1B B1 FA | Brute short key or key in `libil2cpp.so` strings |\n| Custom header \u002F prepended garbage | File larger than expected; magic at offset N | Scan for `\\xAF\\x1B\\xB1\\xFA` pattern in file |\n| RC4\u002FAES at init | `libil2cpp.so` contains crypto init before metadata load | Frida hook on `il2cpp_codegen_initialize_method` |\n\n```bash\n# Search libil2cpp.so for crypto key material near metadata init\nr2 -qc 'iz~metadata\\|iz~global' \u002Ftmp\u002Flibil2cpp.so | head -20\nstrings \u002Ftmp\u002Flibil2cpp.so | grep -iE \"meta|key|init\" | head -20\n```\n\n### zygisk-il2cpp-dumper (runtime dump, bypasses all static obfuscation)\n\n```bash\n# Install Zygisk-Il2CppDumper module via Magisk Manager\n# Flash zip: ZygiskIl2CppDumper-v\u003Cversion>.zip\n# Configure target package in \u002Fdata\u002Fadb\u002Fmodules\u002Fzygisk_il2cpp_dumper\u002Fconfig.json\n\ncat \u002Fdata\u002Fadb\u002Fmodules\u002Fzygisk_il2cpp_dumper\u002Fconfig.json\n# { \"package_name\": \"com.unity.targetgame\" }\n\n# Launch the target app\nadb shell am start -n com.unity.targetgame\u002F.MainActivity\n\n# Dumped files appear in \u002Fdata\u002Flocal\u002Ftmp\u002Fil2cpp_dump\u002F\nadb pull \u002Fdata\u002Flocal\u002Ftmp\u002Fil2cpp_dump\u002F\nls il2cpp_dump\u002F\n# global-metadata.dat  libil2cpp.so  (decrypted at runtime)\n```\n\nFeed the runtime-dumped files to Il2CppDumper per Step 2.\n\n## Step 6: Il2CppInspector (Alternative — Richer Output)\n\n```bash\n# Il2CppInspector CLI mode\nmono Il2CppInspector.exe \\\n  --select-outputs Frida \\\n  --output \u002Ftmp\u002Ffrida-hooks.js \\\n  \u002Ftmp\u002Flibil2cpp.so \u002Ftmp\u002Fglobal-metadata.dat\n\n# Produces a ready-to-load Frida script with all class\u002Fmethod stubs\n# Load and customize the method of interest\n\n# Also supports IDA, C# pseudo-code, and Roslyn output modes\n```\n\n## Evidence\n\n```python\nkg_add_node(\n    kind=\"finding\",\n    label=\"Unity IL2CPP client-side IAP bypass\",\n    props={\n        \"key\": f\"il2cpp-iap-bypass::{package_id}\",\n        \"severity\": \"high\",\n        \"cvss\": 8.1,\n        \"package\": package_id,\n        \"hooked_method\": \"IsPremiumUser \u002F VerifyReceipt\",\n        \"rva\": \"0x\u003Cfrom-dump.cs>\",\n        \"bypass_proof\": \"Frida hook returns true; premium features unlocked\",\n    },\n)\n\nkg_add_node(\n    kind=\"finding\",\n    label=\"Unity IL2CPP anti-cheat bypass\",\n    props={\n        \"key\": f\"il2cpp-anticheat-bypass::{package_id}\",\n        \"severity\": \"medium\",\n        \"method\": \"IsCheatDetected\",\n        \"details\": \"Client-only check; server-authoritative validation absent\",\n    },\n)\n```\n\n## ZFP\n\n1. `dump.cs` excerpt showing `IsPremiumUser` with RVA comment.\n2. Screenshot\u002Fscreen-recording of the patched\u002Fhooked app with\n   premium features unlocked or anti-cheat bypassed.\n3. Frida console output showing hook fired + return value replaced.\n\n## OPSEC Notes\n\n- Il2CppDumper runs entirely offline on extracted APK files. No\n  network activity required for analysis.\n- Static patching changes the APK signature; Play Integrity \u002F SafetyNet\n  will flag it. Use Frida hooks on a rooted device for non-persistent\n  testing.\n- zygisk-il2cpp-dumper requires Zygisk (Magisk Delta or native Zygisk).\n  It runs in the app process at startup and can be detected by some\n  anti-cheat engines (EAC, BattlEye mobile). Use only in scope.\n- Dumped `dump.cs` may contain plaintext user-data class names that\n  reveal the developer's internal naming conventions — treat as\n  sensitive during an engagement.\n\n## Severity Table\n\n| Bug | Severity |\n|---|---|\n| Client-side IAP bypass (server trusts client result) | High 8.1 |\n| License check entirely client-side | High 7.5 |\n| Anti-cheat only client-side (game balance impact) | Medium 5.5 |\n| Encrypted metadata recovered via runtime dump | Informational (enables further bugs) |\n| Hardcoded API key \u002F secret in `dump.cs` string literals | Critical 9.0 |\n\n## References\n\n- Il2CppDumper: https:\u002F\u002Fgithub.com\u002FPerfare\u002FIl2CppDumper\n- Zygisk-Il2CppDumper: https:\u002F\u002Fgithub.com\u002FPerfare\u002FZygisk-Il2CppDumper\n- Il2CppInspector: https:\u002F\u002Fgithub.com\u002Fdjkaty\u002FIl2CppInspector\n- Cross-ref: `mobile\u002Fandroid\u002FSKILL.md` (Frida setup, APK pull)\n- Cross-ref: `mobile\u002Fflutter\u002FSKILL.md` (Dart AOT — different toolchain)\n- Cross-ref: `reverser\u002Ftriage\u002FSKILL.md` (binary triage)\n","# Unity IL2CPP Game Reversing Playbook\n\n> Unity IL2CPP compiles C# to C++ then to native `libil2cpp.so`. The\n> managed bytecode is stripped — `jadx` and `apktool` expose only the\n> thin Java bootstrap and reveal nothing of game logic. This playbook\n> recovers readable symbols and hooks runtime methods for license\u002FIAP\n> bypass and vulnerability assessment.\n\n## Prerequisites\n\n- APK obtained (see `mobile\u002Fandroid\u002FSKILL.md` for pull methods).\n- **Il2CppDumper** (Windows .NET or mono CLI):\n  https:\u002F\u002Fgithub.com\u002FPerfare\u002FIl2CppDumper\n- **Il2CppInspector** (alternative with plugin support):\n  https:\u002F\u002Fgithub.com\u002Fdjkaty\u002FIl2CppInspector\n- Ghidra (via MCP `ghidra` server) or IDA (host-side).\n- Frida + Objection for runtime hooking (see `mobile\u002Fandroid\u002FSKILL.md`\n  Frida setup section).\n- **zygisk-il2cpp-dumper** for runtime metadata on protected apps:\n  https:\u002F\u002Fgithub.com\u002FPerfare\u002FZygisk-Il2CppDumper\n\n## Step 1: Identify Unity IL2CPP App\n\n```bash\nunzip -o base.apk -d \u002Ftmp\u002Fapk-out\u002F\n\n# Confirm IL2CPP backend\nls \u002Ftmp\u002Fapk-out\u002Flib\u002Farm64-v8a\u002F\n# Must contain: libil2cpp.so\n\nls \u002Ftmp\u002Fapk-out\u002Fassets\u002Fbin\u002FData\u002FManaged\u002FMetadata\u002F\n# Must contain: global-metadata.dat\n\n# If only libmono.so present → Mono backend (smali\u002Fjadx works; this skill N\u002FA)\n# If libil2cpp.so present but no global-metadata.dat → encrypted\u002Fobfuscated (go to Step 5)\n\nfile \u002Ftmp\u002Fapk-out\u002Flib\u002Farm64-v8a\u002Flibil2cpp.so\n# output: ELF 64-bit LSB shared object, ARM aarch64\n```\n\n## Step 2: Recover Symbols with Il2CppDumper\n\n```bash\n# Extract libs from APK\ncp \u002Ftmp\u002Fapk-out\u002Flib\u002Farm64-v8a\u002Flibil2cpp.so \u002Ftmp\u002F\ncp \u002Ftmp\u002Fapk-out\u002Fassets\u002Fbin\u002FData\u002FManaged\u002FMetadata\u002Fglobal-metadata.dat \u002Ftmp\u002F\n\n# Run Il2CppDumper (mono CLI on Linux\u002FmacOS)\nmono Il2CppDumper.exe \u002Ftmp\u002Flibil2cpp.so \u002Ftmp\u002Fglobal-metadata.dat \u002Ftmp\u002Fdump-output\u002F\n\n# Windows .NET:\n# Il2CppDumper.exe \u003Clibil2cpp.so> \u003Cglobal-metadata.dat> \u003Coutput-dir>\n```\n\nOutput files:\n| File | Content |\n|---|---|\n| `dump.cs` | All C# class\u002Fmethod\u002Ffield definitions with offsets |\n| `script.json` | Machine-readable symbol map (used by IDA\u002FGhidra scripts) |\n| `il2cpp.h` | C-style struct definitions for IL2CPP internals |\n| `stringliteral.json` | All managed string literals with addresses |\n\n```bash\n# Quick scan of dump.cs for interesting classes\ngrep -i \"licen\\|premium\\|iap\\|purchase\\|unlock\\|cheat\\|anti\\|integrity\" \u002Ftmp\u002Fdump-output\u002Fdump.cs | head -30\n\n# Find method offsets for hooks\ngrep -A2 \"IsPremium\\|CheckLicense\\|VerifyReceipt\\|IsSubscribed\" \u002Ftmp\u002Fdump-output\u002Fdump.cs\n# Output: \u002F\u002F RVA: 0x\u003Coffset>  — this is the function RVA in libil2cpp.so\n```\n\n## Step 3: Apply Symbols in Ghidra \u002F IDA\n\n### Ghidra (via MCP ghidra server — batch mode)\n\n```\n# 1. Import libil2cpp.so into Ghidra project\n# 2. Run auto-analysis (aarch64)\n# 3. Execute the Il2CppDumper Ghidra script:\n#    Script: ghidra_with_struct.py  (from Il2CppDumper\u002Ftools\u002F)\n#    Input: script.json + il2cpp.h\n# 4. All methods now have their managed C# names\n```\n\n```bash\n# Command-line Ghidra headless analysis + script\n\"$GHIDRA_HOME\u002Fsupport\u002FanalyzeHeadless\" \u002Ftmp\u002Fghidra-project IL2CPP \\\n  -import \u002Ftmp\u002Flibil2cpp.so \\\n  -postScript ghidra_with_struct.py \u002Ftmp\u002Fdump-output\u002Fscript.json \\\n  -processor AARCH64:LE:64:v8A \\\n  -noanalysis\n```\n\n### IDA (host-side)\n\n```python\n# In IDA scripting console (Python):\n# Run ida_with_struct_py3.py from Il2CppDumper\u002Ftools\u002F\n# File → Script File → ida_with_struct_py3.py\n# Provide path to script.json when prompted\n# IDA applies all function names + struct types\n```\n\nAfter symbol restore, navigate to `IsPremiumUser`, `CheckLicense`,\n`VerifyIAP`, `IsCheatDetected`, etc. by name.\n\n## Step 4: Frida Runtime Hooking\n\n### Hook via RVA from dump.cs\n\n```javascript\n\u002F\u002F Read RVA from dump.cs comment line: \u002F\u002F RVA: 0x\u003Chex>\n\u002F\u002F Base address of libil2cpp.so changes per run; use Module.findBaseAddress\n\nvar il2cpp_base = Module.findBaseAddress(\"libil2cpp.so\");\n\n\u002F\u002F Example: hook IsPremiumUser at RVA 0x1A4F80\nvar RVA = 0x1A4F80;\nvar isPremium = il2cpp_base.add(RVA);\n\nInterceptor.attach(isPremium, {\n    onEnter: function(args) {\n        console.log(\"[+] IsPremiumUser called\");\n    },\n    onLeave: function(retval) {\n        console.log(\"[+] Original return:\", retval.toInt32());\n        retval.replace(ptr(1));  \u002F\u002F return true\n        console.log(\"[+] Replaced with: 1\");\n    }\n});\n```\n\n```bash\n# Load hook script\nfrida -U -f com.unity.targetgame -l hook-il2cpp.js --no-pause\n```\n\n### Static libil2cpp.so patch (persistent, no Frida needed)\n\n```bash\n# Patch return value of IsPremiumUser at computed file offset\npython3 - \u003C\u003C'EOF'\nimport struct\n\nRVA = 0x1A4F80\nLOAD_OFFSET = 0x0  # verify with readelf -l libil2cpp.so\n\nwith open(\"\u002Ftmp\u002Flibil2cpp.so\", \"r+b\") as f:\n    file_offset = RVA - LOAD_OFFSET\n    f.seek(file_offset)\n    # AArch64: MOV W0, #1 (0x20008052) + RET (0xC003_5FD6)\n    f.write(b\"\\x20\\x00\\x80\\x52\\xC0\\x03\\x5F\\xD6\")\nprint(f\"[+] Patched at file offset 0x{file_offset:X}\")\nEOF\n\n# Repack APK\napktool b \u002Ftmp\u002Fapk-smali\u002F -o \u002Ftmp\u002Fpatched.apk\n# Replace libs\u002Farm64-v8a\u002Flibil2cpp.so with patched version\nzip -u \u002Ftmp\u002Fpatched.apk lib\u002Farm64-v8a\u002Flibil2cpp.so\nuber-apk-signer.jar --allowResign -a \u002Ftmp\u002Fpatched.apk -o \u002Ftmp\u002F\nadb install \u002Ftmp\u002Fpatched-aligned-signed.apk\n```\n\n## Step 5: Encrypted \u002F Obfuscated global-metadata.dat\n\nSome apps (particularly heavily monetized games) encrypt or obfuscate\n`global-metadata.dat` to frustrate IL2CPP reversing.\n\n### Detect obfuscation\n\n```bash\n# Check magic bytes — valid global-metadata starts with: AF 1B B1 FA\nxxd \u002Ftmp\u002Fglobal-metadata.dat | head -2\n# If first 4 bytes ≠ AF 1B B1 FA → encrypted\u002Fcustom header\n```\n\n### Common obfuscation patterns\n\n| Pattern | Detection | Counter |\n|---|---|---|\n| XOR with static key | First 4 bytes XOR'd from AF 1B B1 FA | Brute short key or key in `libil2cpp.so` strings |\n| Custom header \u002F prepended garbage | File larger than expected; magic at offset N | Scan for `\\xAF\\x1B\\xB1\\xFA` pattern in file |\n| RC4\u002FAES at init | `libil2cpp.so` contains crypto init before metadata load | Frida hook on `il2cpp_codegen_initialize_method` |\n\n```bash\n# Search libil2cpp.so for crypto key material near metadata init\nr2 -qc 'iz~metadata\\|iz~global' \u002Ftmp\u002Flibil2cpp.so | head -20\nstrings \u002Ftmp\u002Flibil2cpp.so | grep -iE \"meta|key|init\" | head -20\n```\n\n### zygisk-il2cpp-dumper (runtime dump, bypasses all static obfuscation)\n\n```bash\n# Install Zygisk-Il2CppDumper module via Magisk Manager\n# Flash zip: ZygiskIl2CppDumper-v\u003Cversion>.zip\n# Configure target package in \u002Fdata\u002Fadb\u002Fmodules\u002Fzygisk_il2cpp_dumper\u002Fconfig.json\n\ncat \u002Fdata\u002Fadb\u002Fmodules\u002Fzygisk_il2cpp_dumper\u002Fconfig.json\n# { \"package_name\": \"com.unity.targetgame\" }\n\n# Launch the target app\nadb shell am start -n com.unity.targetgame\u002F.MainActivity\n\n# Dumped files appear in \u002Fdata\u002Flocal\u002Ftmp\u002Fil2cpp_dump\u002F\nadb pull \u002Fdata\u002Flocal\u002Ftmp\u002Fil2cpp_dump\u002F\nls il2cpp_dump\u002F\n# global-metadata.dat  libil2cpp.so  (decrypted at runtime)\n```\n\nFeed the runtime-dumped files to Il2CppDumper per Step 2.\n\n## Step 6: Il2CppInspector (Alternative — Richer Output)\n\n```bash\n# Il2CppInspector CLI mode\nmono Il2CppInspector.exe \\\n  --select-outputs Frida \\\n  --output \u002Ftmp\u002Ffrida-hooks.js \\\n  \u002Ftmp\u002Flibil2cpp.so \u002Ftmp\u002Fglobal-metadata.dat\n\n# Produces a ready-to-load Frida script with all class\u002Fmethod stubs\n# Load and customize the method of interest\n\n# Also supports IDA, C# pseudo-code, and Roslyn output modes\n```\n\n## Evidence\n\n```python\nkg_add_node(\n    kind=\"finding\",\n    label=\"Unity IL2CPP client-side IAP bypass\",\n    props={\n        \"key\": f\"il2cpp-iap-bypass::{package_id}\",\n        \"severity\": \"high\",\n        \"cvss\": 8.1,\n        \"package\": package_id,\n        \"hooked_method\": \"IsPremiumUser \u002F VerifyReceipt\",\n        \"rva\": \"0x\u003Cfrom-dump.cs>\",\n        \"bypass_proof\": \"Frida hook returns true; premium features unlocked\",\n    },\n)\n\nkg_add_node(\n    kind=\"finding\",\n    label=\"Unity IL2CPP anti-cheat bypass\",\n    props={\n        \"key\": f\"il2cpp-anticheat-bypass::{package_id}\",\n        \"severity\": \"medium\",\n        \"method\": \"IsCheatDetected\",\n        \"details\": \"Client-only check; server-authoritative validation absent\",\n    },\n)\n```\n\n## ZFP\n\n1. `dump.cs` excerpt showing `IsPremiumUser` with RVA comment.\n2. Screenshot\u002Fscreen-recording of the patched\u002Fhooked app with\n   premium features unlocked or anti-cheat bypassed.\n3. Frida console output showing hook fired + return value replaced.\n\n## OPSEC Notes\n\n- Il2CppDumper runs entirely offline on extracted APK files. No\n  network activity required for analysis.\n- Static patching changes the APK signature; Play Integrity \u002F SafetyNet\n  will flag it. Use Frida hooks on a rooted device for non-persistent\n  testing.\n- zygisk-il2cpp-dumper requires Zygisk (Magisk Delta or native Zygisk).\n  It runs in the app process at startup and can be detected by some\n  anti-cheat engines (EAC, BattlEye mobile). Use only in scope.\n- Dumped `dump.cs` may contain plaintext user-data class names that\n  reveal the developer's internal naming conventions — treat as\n  sensitive during an engagement.\n\n## Severity Table\n\n| Bug | Severity |\n|---|---|\n| Client-side IAP bypass (server trusts client result) | High 8.1 |\n| License check entirely client-side | High 7.5 |\n| Anti-cheat only client-side (game balance impact) | Medium 5.5 |\n| Encrypted metadata recovered via runtime dump | Informational (enables further bugs) |\n| Hardcoded API key \u002F secret in `dump.cs` string literals | Critical 9.0 |\n\n## References\n\n- Il2CppDumper: https:\u002F\u002Fgithub.com\u002FPerfare\u002FIl2CppDumper\n- Zygisk-Il2CppDumper: https:\u002F\u002Fgithub.com\u002FPerfare\u002FZygisk-Il2CppDumper\n- Il2CppInspector: https:\u002F\u002Fgithub.com\u002Fdjkaty\u002FIl2CppInspector\n- Cross-ref: `mobile\u002Fandroid\u002FSKILL.md` (Frida setup, APK pull)\n- Cross-ref: `mobile\u002Fflutter\u002FSKILL.md` (Dart AOT — different toolchain)\n- Cross-ref: `reverser\u002Ftriage\u002FSKILL.md` (binary triage)\n",{"name":5,"metadata":23,"description":7,"allowed-tools":28},{"tags":24,"subdomain":25,"when_to_use":26,"mitre_attack":27},"unity, il2cpp, game, reverse-engineering, il2cppdumper, global-metadata, ghidra, frida, iap, anti-cheat","mobile","unity il2cpp libil2cpp.so global-metadata.dat il2cppdumper il2cppinspector mono game reversing anti-cheat license iap inapp purchase ghidra ida symbol restore zygisk","T1635, T1406, T1407","Bash Read Write","main","376de63e2b186eeb9856476ae89186e62b1d3fbe","packages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fmobile\u002Fandroid\u002Fil2cpp","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon","https:\u002F\u002Fgithub.com\u002Fdnzengou","2026-11-09 16:34:40",{"source":8,"skillName":5,"commands":36,"prompt":46,"zipAvailable":47},[37,40,43],{"tool":38,"command":39},"npx","npx skills add dnzengou\u002Fevo-decepticon --skill il2cpp",{"tool":41,"command":42},"bunx","bunx skills add dnzengou\u002Fevo-decepticon --skill il2cpp",{"tool":44,"command":45},"pnpm","pnpm dlx skills add dnzengou\u002Fevo-decepticon --skill il2cpp","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fmobile\u002Fandroid\u002Fil2cpp\u002FSKILL.md",true,[],[50,57,64,71,78,85],{"skillNo":51,"name":52,"nameZh":6,"description":53,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":54,"categories":55,"keywords":56,"publishedAt":18},"01M78JAX15GZR5Q5S7RMPWFX43","wps-pixie-dust","WPS Pixie-Dust offline nonce attack (reaver -K \u002F pixiewps) and fallback online PIN brute (bully) to recover the AP's WPA PSK without capturing a handshake.","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fwireless\u002Fwps-pixie-dust\u002FSKILL.md",[],[],{"skillNo":58,"name":59,"nameZh":6,"description":60,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":61,"categories":62,"keywords":63,"publishedAt":18},"01M78JARXE0ZER8P81SFD024YP","wpa3-sae","WPA3-SAE transition-mode downgrade (DragonShift), SSID Confusion CVE-2023-52424, Dragonblood side-channels, and SAE captive-portal credential recovery against WPA3-Personal networks.","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fwireless\u002Fwpa3-sae\u002FSKILL.md",[],[],{"skillNo":65,"name":66,"nameZh":6,"description":67,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":68,"categories":69,"keywords":70,"publishedAt":18},"01M78JANJNH8VMR0CK1Y6AM74G","wpa2-psk","WPA\u002FWPA2-PSK handshake capture via targeted deauth + PMKID (no deauth required) + offline hashcat cracking. The most common consumer\u002FSMB encryption mode in 2026.","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fwireless\u002Fwpa2-psk\u002FSKILL.md",[],[],{"skillNo":72,"name":73,"nameZh":6,"description":74,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":75,"categories":76,"keywords":77,"publishedAt":18},"01M78JAFCYR2BAJF7KH0ZCXREA","wpa-enterprise-eap","WPA\u002FWPA2\u002FWPA3-Enterprise (802.1X\u002FEAP) rogue-RADIUS evil-twin for MSCHAPv2 capture, GTC downgrade, and PEAP relay. MSCHAPv2 capture equals a NetNTLM hash — the primary wireless on-ramp to Active Directory.","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fwireless\u002Fwpa-enterprise-eap\u002FSKILL.md",[],[],{"skillNo":79,"name":80,"nameZh":6,"description":81,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":82,"categories":83,"keywords":84,"publishedAt":18},"01M78JAAQ5T08FR9MY5SFNRWBM","krack-fragattacks","KRACK key-reinstallation (CVE-2017-13077..13082) and FragAttacks fragmentation\u002Faggregation flaws (CVE-2020-24586..24588, CVE-2020-26139..26147) against legacy or embedded 802.11 supplicants with poor patch cadence.","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fwireless\u002Fkrack-fragattacks\u002FSKILL.md",[],[],{"skillNo":86,"name":87,"nameZh":6,"description":88,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":89,"categories":90,"keywords":91,"publishedAt":18},"01M78JA6799JQZE0M9B21HRMGY","evil-twin-karma","Evil-twin rogue AP with KARMA\u002FMana PNL-probe response, captive-portal credential capture, and post-association MITM for PSK\u002Fopen networks. Distinct from wpa-enterprise-eap which targets 802.1X.","https:\u002F\u002Fgithub.com\u002Fdnzengou\u002Fevo-decepticon\u002Fblob\u002Fmain\u002Fpackages\u002Fdecepticon\u002Fdecepticon\u002Fskills\u002Fstandard\u002Fwireless\u002Fevil-twin-karma\u002FSKILL.md",[],[]]