mcp-flutter-apk-injector
This server provides a complete toolkit for Android APK reverse engineering and Flutter runtime injection, enabling a decompile → analyze → synthesize → inject → patch → repackage pipeline for security testing and authorized customization.
Decompile APK: Disassemble an APK into Smali code, native libraries, resources, and a decoded AndroidManifest.xml.
Analyze Injection Surface: Scan the decompiled workspace to identify optimal injection points (Application class, entry Activity, JNI loading sites, pre-existing Flutter classes).
Synthesize Flutter Payload: Compile a Flutter project and extract required runtime artifacts (libflutter.so, libapp.so, flutter_assets, ICU data) for target ABIs.
Inject Flutter Runtime & Smali: Merge Flutter engine assets, native libraries, and custom Smali glue code, supporting multiple injection modes (activity_overlay, view_tree_injection, headless_engine, direct_application_hook) and optional MethodChannel bridge.
Patch Manifest & Configuration: Modify AndroidManifest.xml to add permissions (INTERNET, WAKE_LOCK), override the Application class, add FlutterActivity, and adjust cleartext traffic settings.
Recompile, Align & Sign: Rebuild the modified APK with apktool, align with zipalign, and cryptographically sign with apksigner (V1/V2/V3 schemes).
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-flutter-apk-injectorDecompile the APK and inject the Flutter runtime, then repackage it."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-flutter-apk-injector
The World's Most Advanced Memory-Aware Model Context Protocol (MCP) Server for Android APK Reverse Engineering, Dalvik/Smali Bytecode Refactoring, Native JNI Tracing, and Flutter Runtime Overlay Injection.
🇬🇧 English Documentation | 🇸🇦 التوثيق باللغة العربية
🇬🇧 English Documentation
🌟 Executive Overview & Key Advantages
mcp-flutter-apk-injector is a highly developed, enterprise-grade Model Context Protocol (MCP) Server designed for security researchers, reverse engineers, and mobile penetration testers. It seamlessly combines automated static/dynamic Android binary analysis, Dalvik/ART Smali stack frame balance refactoring, native .so library symbol tracing, and Flutter Add-to-App v2 runtime injection.
Powered natively by the Hermes+ Master Agent Engine, this server elevates standard tool-dispatching into an autonomous, self-correcting, stateful agentic system featuring persistent session memory, searchable patch history graphs, native MCP resource streams, and zero-argument resilient prompt handlers.
┌─────────────────────────────────────────┐
│ AI Assistant / MCP Client (Claude, │
│ Antigravity IDE, Cursor, Windsurf) │
└────────────────────┬────────────────────┘
│
▼
┌────────────────────────────────────────────────────────────────────────────────────────┐
│ mcp-flutter-apk-injector (v0.5.2) │
│ │
│ ┌────────────────────────┐ ┌─────────────────────────┐ ┌─────────────────────────┐ │
│ │ Hermes+ Agent Engine │ │ Session Memory Manager │ │ Embedded Skills & Prompts│ │
│ │ (Persona & Rules Graph)│ │ (.mcp_memory/session) │ │ (/scan, /decompile, ...)│ │
│ └───────────┬────────────┘ └────────────┬────────────┘ └────────────┬────────────┘ │
└──────────────┼────────────────────────────┼────────────────────────────┼───────────────┘
│ │ │
▼ ▼ ▼
┌────────────────────────────────────────────────────────────────────────────────────────┐
│ THE 9 ENTERPRISE MCP TOOLS & RESOURCES │
│ │
│ [decompile_apk] ──► [analyze_surface] ──► [synthesize_payload] ──► [inject_flutter] │
│ [patch_manifest] ──► [recompile_align_sign] ──► [get_context] ──► [update_memory] │
└────────────────────────────────────────────────────────────────────────────────────────┘🧠 The Hermes+ Agent Persona & MCP Skill Ecosystem
1. Embedded Persona: Hermes+ (Elite Android Systems Architect)
Hermes+ is an embedded AI assistant identity specialized in ARM/ARM64 binary inspection, JNI method hooks, Dalvik register stack allocation (v0-vN, p0-pN), and game engine asset modding (Lua/C++ symbols).
2. Native MCP Skills (.agents/skills/)
🧠
hermes-apk-reverse-engineering: Guides static/dynamic DEX bytecode refactoring, register frame bumping (.registers N), native.solibrary deployment, and zero-crash UI overlay injection.⚡
mcp-toolchain-orchestrator: Manages MCP server quality assurance, zero-argument prompt resiliency, automated testing, and distribution workflows.
📡 Native MCP Resources
resource://agent/persona: Hermes+ identity, system prompt, and core reverse engineering rules.resource://agent/rules: 5-step deep reverse engineering protocol.resource://agent/skills/hermes-apk-reverse-engineering: Reverse engineering skill document.resource://agent/skills/mcp-toolchain-orchestrator: Toolchain orchestrator skill document.resource://memory/session: Live JSON session memory graph state.resource://memory/patch_history: Audit log of applied Smali and Manifest patches.
⚙️ 5-Step Deep Reverse Engineering Pipeline
[Target Android .apk / Workspace]
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ STEP 1: Binary & Asset Deconstruction (decompile_apk) │
│ Extract DEX Smali bytecode, native lib/*.so trees, AXML, assets/ │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ STEP 2: Precision Native & Smali Tracing (analyze_injection_surface) │
│ Trace UI click handlers (View$OnClickListener), 0x7f... R-ids, │
│ JNI native symbols, and Lua script hook points │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ STEP 3: Seamless Payload Injection (inject_flutter_runtime_and_smali) │
│ Synthesize Flutter engine payload; balance register stack frames │
│ (.registers N); inject native-looking UI without crashes │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ STEP 4: Manifest Surgery & Assembly (patch_manifest & recompile_align) │
│ Patch AndroidManifest.xml (permissions, Application override, ABIs); │
│ Rebuild (apktool b), 4-byte Align (zipalign), Sign (apksigner) │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ STEP 5: Architectural Summary & Session Memory Persistence │
│ Document modified Smali paths, .so symbol offsets, injected channels, │
│ register maps, and verified output APK location │
└───────────────────────────────────────────────────────────────────────────┘🛠️ The 9 Enterprise MCP Tools
Tool Name | Detailed Function & Output |
| Disassemble target APK into Smali bytecode, native libraries ( |
| Scan decompiled APK workspace to identify optimal injection hooks, entry Activity, Application class, JNI loading hooks, native ABIs, and recommended patch points. |
| Extract Flutter runtime artifacts ( |
| Inject Flutter assets, native |
| Patch |
| Rebuild workspace with |
| Retrieve Hermes+ persona, loaded skills, live memory summary, and pipeline telemetry. |
| Explicitly update active session memory state with notes, identified targets, or patch logs. |
| Search and inspect historical patch logs, register allocations, and decompilation metadata. |
🎮 The 4 Dynamic Injection Modes
Injection Strategy | Primary Smali Target | Description |
|
| Launches a dedicated Flutter Activity reusing a pre-warmed cached engine for custom UI overlays inside apps or mobile games. |
| Launcher Activity | Programmatically attaches |
|
| Initializes a background engine without UI for headless Dart execution, channel routing, and telemetry. |
|
| Directly instruments existing Application class in Smali without modifying |
⚡ Agent Prompts & Slash Commands
/scan: Diagnostic audit scan of decompiled APK workspace, entry points, Smali structure, and native ABIs./decompile: Disassemble target.apkinto Smali bytecode and resources usingapktool./inject: Execute Flutter runtime payload & Smali glue code injection into target APK./patch: PatchAndroidManifest.xml(application class, hardware acceleration, cleartext traffic, permissions)./recompile: Repackage (apktool b), byte-align (zipalign), and cryptographically sign (apksigner) modified target./pipeline: Full automated end-to-end decompilation ➔ analysis ➔ payload synthesis ➔ injection ➔ manifest patch ➔ recompilation pipeline./memory: Inspect active session memory state, historical patch logs, and allocated register frames./hermes_guide: Display Hermes+ architecture rules and reverse engineering guidelines.
🚀 Quick Start & Client Configuration (v0.5.2)
📦 NPM Install & NPX Execution
# Global Install
npm install -g mcp-flutter-apk-injector@latest
# NPX Direct Run
npx -y mcp-flutter-apk-injector@latestClaude Desktop Configuration (claude_desktop_config.json)
{
"mcpServers": {
"mcp-flutter-apk-injector": {
"command": "npx",
"args": ["-y", "mcp-flutter-apk-injector@latest"]
}
}
}Antigravity IDE / Generic MCP Client (stdio)
{
"mcpServers": {
"mcp-flutter-apk-injector": {
"command": "npx",
"args": ["-y", "mcp-flutter-apk-injector@latest"],
"env": {
"MCP_FLUTTER_LOG_LEVEL": "info"
}
}
}
}Related MCP server: SO Analyzer MCP
🇸🇦 التوثيق باللغة العربية
🌟 الملخص التنفيذي والمميزات الاستثنائية
خادم mcp-flutter-apk-injector هو خادم Model Context Protocol (MCP) الأكثر تطوراً واحترافية عالمياً والمخصص لـ الهندسة العكسية لتطبيقات أندرويد APK، إعادة هيكلة شفرات Smali/DEX، تتبع رموز JNI الأصلية، وحقن محرك تشغيل Flutter (Add-to-App v2).
مدعوماً بالمحرك الذكي Hermes+ Master Agent Engine، ينتقل هذا الخادم من مجرد خادم أدوات عادي إلى منظومة ذكاء اصطناعي ذاتية التوجيه والتصحيح (Stateful Agentic System) تمتلك ذاكرة جلسات مستمرة، ورسم بياني محلي قابل للبحث لتعديلات الشفرات، وموارد MCP أصلية، وأوامر تفاعلية مرنة ضد أخطاء المعاملات.
🧠 منظومة الوكيل الذكي Hermes+ ومهارات MCP Skills
1. شخصية الوكيل المدمجة: Hermes+
شخصية ذكاء اصطناعي مدمجة تخصصية في تحليل معمارية تطبيقات وألعاب أندرويد (ARM/ARM64)، فحص رموز JNI، موازنة سجلات Dalvik Stack (v0-vN, p0-pN)، وتعديل أصول المحركات مثل Lua/C++.
2. مهارات MCP المدمجة (.agents/skills/)
🧠
hermes-apk-reverse-engineering: المهارة الرئيسية لإعادة هيكلة شفرات DEX/Smali، موازنة السجلات (.registers N)، زرع المكتبات الأصلية.soوحقن واجهات Flutter بدون انهيار التطبيق.⚡
mcp-toolchain-orchestrator: المهارة الرئيسية لإدارة وتنسيق أدوات MCP، المعالجة السريعة للأوامر بدون وسائط، وأتمتة الاختبارات والنشر.
📡 موارد MCP الأصلية (MCP Resources)
resource://agent/persona: هوية Hermes+ وقواعد الهندسة العكسية.resource://agent/rules: بروتوكول الخطوات الخمس للهندسة العكسية.resource://agent/skills/hermes-apk-reverse-engineering: وثيقة مهارة الهندسة العكسية.resource://agent/skills/mcp-toolchain-orchestrator: وثيقة مهارة تنسيق الأدوات.resource://memory/session: حالة الذاكرة الحية للجلسة الحالية بصيغة JSON.resource://memory/patch_history: سجل تعديلات وترقيعات شفرات Smali و Manifest.
⚙️ مسار العمل الخماسي للهندسة العكسية (5-Step Pipeline)
[تطبيق أندرويد APK Target / مساحة العمل]
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ الخطوة 1: تفكيك البناء والأصول (decompile_apk) │
│ استخراج شفرات Smali DEX، أشجار مكتبات lib/*.so، ملفات AXML والأصول │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ الخطوة 2: التتبع الدقيق لرموز JNI و Smali (analyze_injection_surface) │
│ تتبع معالجات النقر (View$OnClickListener)، معرفات 0x7f... R-ids، │
│ رموز JNI الأصلية، ونقاط خطاطيف سكربتات Lua │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ الخطوة 3: زرع وحقن المحرك والحمولة (inject_flutter_runtime_and_smali) │
│ بناء أصول Flutter؛ موازنة سجلات الـ Stack (.registers N)؛ │
│ حقن الواجهات بشكل أصيل ودون حدوث انهيار │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ الخطوة 4: تعديل الـ Manifest وإعادة التجميع (patch_manifest & recompile) │
│ تعديل AndroidManifest.xml (التصاريح، كلاس التطبيق، المعماريات)؛ │
│ إعادة التجميع (apktool b)، المحاذاة (zipalign)، التوقيع (apksigner) │
└─────────────────────────────────────┬─────────────────────────────────────┘
│
▼
┌───────────────────────────────────────────────────────────────────────────┐
│ الخطوة 5: التقرير المعماري وحفظ الذاكرة (Session Memory Persistence) │
│ توثيق مسارات Smali المعدلة، إزاحات مكتبات .so، القنوات المحقونة، │
│ وخريطة السجلات وموقع الـ APK النهائي المكتمل │
└───────────────────────────────────────────────────────────────────────────┘🛠️ الأدوات الـ 9 الاحترافية في MCP
اسم الأداة | الوظيفة التفصيلية والمخرجات |
| تفكيك ملف APK الهدف إلى شفرات Smali bytecode ومكتبات نظام وموارد وفك تشفير AndroidManifest.xml، مع تحديث الذاكرة تلقائياً. |
| مسح مساحة العمل وتحديد كلاس التطبيق والـ Activity الرئيسي ومواقع تحميل JNI والـ ABIs والتوصيات. |
| استخراج أصول تشغيل Flutter ( |
| زرع أصول وقواعد Smali ومكتبات النظام مع موازنة سجلات Stack. |
| تعديل |
| إعادة التجميع ( |
| استرجاع هوية Hermes+ والمهارات المتاحة وحالة الذاكرة الحية والسياق الحالي. |
| تحديث ذاكرة الجلسة الحية بملحوظات أو أهداف أو سجلات تعديل جديدة. |
| البحث والافتراش في سجلات الترقيع والذاكرة والمخرجات السابقة. |
🎮 أنماط الحقن الـ 4 المتقدمة
نمط الحقن | الهدف الرئيسي في Smali | الوصف المعماري |
|
| تشغيل Activity مخصص يرث من |
| Launcher Activity | إرفاق |
|
| تشغيل محرك |
|
| تعديل كلاس الـ |
⚡ أوامر Tigger والتفاعل السريع (Slash Commands)
/scan: فحص وتشخيص السطح القابل للحقن داخل مساحة عمل الـ APK وتحديد مكتبات النظام ودرجات الأمان./decompile: تفكيك ملف الـ APK الهدف إلى شفرات Smali وموارد باستخدامapktool./inject: تنفيذ حقن بيئة تشغيل Flutter ومكتبات النظام وتوليد شفرات الـ Smali التكيفية./patch: تعديل ملفAndroidManifest.xml(كلاس التطبيق، التسريع البرمجي، تصاريح الشبكة والـ Cleartext Traffic)./recompile: إعادة تجميع التطبيق (apktool b)، محاذاة البيانات (zipalign) والتوقيع الرقمي (apksigner)./pipeline: المسار الآلي الكامل الشامل: تفكيك ➔ تحليل ➔ بناء ➔ حقن ➔ تعديل ➔ إعادة تجميع وتوقيع./memory: فحص وتفتيش ذاكرة الجلسة الحية وسجل الترقيعات والمجموعات المسجلة./hermes_guide: عرض قواعد معمارية Hermes+ وإرشادات الهندسة العكسية.
💻 متطلبات النظام
Node.js >= 18.0.0
بيئة جافا / JDK (مطلوبة لأدوات
apktoolوapksigner)أدوات بناء Android SDK (
zipalignوapksigner— يتم اكتشافها تلقائياً منANDROID_HOMEأو متغيرات النظام)apktool مثبت على متغيرات النظام PATH
Flutter SDK (مطلوب فقط عند استدعاء أداة
synthesize_flutter_payload)
🧪 التطوير والاختبار
# تثبيت التبعيات المحلية
npm install
# بناء مشروع TypeScript إلى dist/
npm run build
# فحص الأنواع دون إخراج
npm run typecheck
# فحص تنسيق الشفرة والأخطاء البرمجية
npm run lint
# تشغيل حزمة اختبارات Vitest (40 اختباراً)
npm test📜 License / الترخيص
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityDmaintenanceProvides a one-stop automated solution for Android APK security analysis by integrating tools like JEB, JADX, APKTOOL, FlowDroid, and MobSF into unified MCP standard API interfaces.Last updated11
- Flicense-qualityDmaintenanceEnables analysis of native Android libraries (SO files) and Flutter applications, including decompilation, function identification, SSL certificate bypass patching, and binary modification through 30+ specialized tools.Last updated10
- Flicense-qualityDmaintenanceIntegrates multiple Android APK security analysis tools into MCP standard APIs for automated static and dynamic analysis and vulnerability detection.Last updated
- Alicense-qualityCmaintenanceEnables authorized Android security testing with static and dynamic analysis, Frida instrumentation, storage inspection, and traffic interception via MCP tools.Last updatedMIT
Related MCP Connectors
Remote MCP for Android CLI agent build gate, structured receipts, audit logs, and reviewer-ready evi
Security scanner for MCP servers. Detect vulnerabilities, prompt injection, and tool poisoning.
Static MCP manifest and tool-policy security preflight with signed input-redacted receipts
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/MarwanDevSpace/mcp-flutter-apk-injector'
If you have feedback or need assistance with the MCP directory API, please join our Discord server