English · 简体中文 · 繁體中文 · 日本語 · 한국어 · Español · Français · Deutsch · Português · Русский · العربية · हिन्दी · Bahasa Indonesia · Tiếng Việt · ไทย · Italiano · Türkçe
⚠️ Chỉ dùng cho học tập và giảng dạy. Không dùng cho hành vi bất hợp pháp, crack trái phép, xâm phạm bản quyền hay vượt bảo vệ của bên thứ ba. Tuân thủ pháp luật địa phương và điều khoản ứng dụng. Người dùng chịu trách nhiệm nếu lạm dụng.
MCP Server giải nén Android + phân tích smali. Trong Cursor / Claude: quản lý thiết bị, phát hiện packer, unpack tĩnh / BlackDex / Frida, dex→smali, tìm chuỗi API.
Repo: https://github.com/TimeCyber/DexAndroid
| Khả năng | Công cụ MCP | Ghi chú |
|---|---|---|
| Devices | list_devices |
Connected ADB devices |
| Packages | list_packages |
Optional keyword filter |
| Packer detect | detect_packer |
360 / Tencent / Bangcle / ijiami / Alibaba, etc. |
| Pull APK | pull_apk |
Installed app (+ splits) |
| Static unpack | static_unpack |
Extract classes*.dex |
| No-Root unpack | blackdex_prepare / blackdex_pull |
BlackDex memory dump |
| Root unpack | frida_prepare / frida_unpack |
frida-server + frida-dexdump |
| Decompile | dex_to_smali |
baksmali → smali |
| Analyze | smali_list_classes / smali_read_class / smali_search |
List / read / regex |
| Phương pháp | Root? | Khi nào |
|---|---|---|
| Static | No | Unpacked apps or shell/resources only |
| BlackDex | No | Most protected apps |
| Frida | Yes | Strong packers / fuller dumps |
- Windows / macOS / Linux (docs use Windows examples)
- Node.js ≥ 18
- ADB on PATH, or set
ADB_PATH - Java 8+ (for baksmali via
dex_to_smali) - Optional: BlackDex; rooted device +
frida-server;pip install frida-tools frida-dexdump
Place baksmali fat jar / frida-server / BlackDex under local tools/ (large binaries are gitignored).
git clone https://github.com/TimeCyber/DexAndroid.git
cd DexAndroid
npm install
npm run buildKhởi động MCP (stdio):
npm start
# node dist/index.jsChế độ dev:
npm run devThêm vào .cursor/mcp.json (đổi đường dẫn):
{
"mcpServers": {
"dex-android-unpack": {
"command": "node",
"args": ["E:/DexAndroid/dist/index.js"],
"env": {
"ADB_PATH": "E:/Android/Sdk/platform-tools/adb.exe",
"DEX_OUT_DIR": "E:/DexAndroid/unpack-output"
}
}
}
}Khởi động lại Cursor / tải lại MCP.
| Biến | Ý nghĩa | Mặc định |
|---|---|---|
ADB_PATH |
adb executable | adb |
DEX_OUT_DIR |
Default output dir | <cwd>/unpack-output |
BAKSMALI_JAR |
baksmali jar | auto-discover under tools/ |
list_devicesor prepare localapkPath.detect_packer.static_unpack→classes*.dex.dex_to_smali→ smali folder.smali_search/smali_read_class.
Note: Protected apps often yield only the shell via static unpack—use BlackDex / Frida for business code.
list_devices.blackdex_preparewithblackdexApkPath.- Unpack the target app in BlackDex UI.
blackdex_pullwithtargetPkg.dex_to_smalithensmali_*.
- Rooted device (e.g. Magisk),
adbready. frida_prepareto push/starttools/frida-server.- Matching
frida/frida-dexdumplocally (prefer 16.x). frida_unpackwithpkg, preferspawn: true,deepSearch: true.dex_to_smalion output, then analyze.
If Frida 17 attach fails, align tools to 16.x; some devices need temporary setenforce 0.
smali_list_classes smaliDir=.../smali keyword=login
smali_search smaliDir=.../smali pattern=https?://|/api/|publicClient/
smali_read_class smaliDir=.../smali className=com.example.api.ApiService
DexAndroid/
├── src/ # MCP server (TypeScript)
│ ├── index.ts
│ ├── adb.ts
│ ├── detect.ts
│ ├── smali.ts
│ └── unpack/
├── dist/
├── examples/ # Damai / Huaxi sample smali.zip + docs
├── tools/ # baksmali / frida-server / BlackDex (local)
├── unpack-output/ # local dumps (gitignored)
├── package.json
└── README.md
Xem examples/ (smali dạng zip):
| Ví dụ | Đường dẫn | Nội dung |
|---|---|---|
| Damai | examples/damai/ |
Frida smali.zip + API docs |
| Huaxi Maternity | examples/huaxi/ |
Static smali.zip (info.cd120.two) |
Sau khi giải nén, dùng smali_*.
| Tool | Params |
|---|---|
detect_packer |
apkPath or pkg, optional serial |
pull_apk |
pkg, optional outDir / serial |
static_unpack |
apkPath or pkg, optional outDir |
blackdex_prepare |
blackdexApkPath, optional serial |
blackdex_pull |
targetPkg, optional outDir / serial |
frida_prepare |
optional serial / serverLocalPath |
frida_unpack |
pkg, optional spawn / deepSearch / outDir |
dex_to_smali |
dexInput, optional outDir |
smali_list_classes |
smaliDir, optional keyword |
smali_read_class |
smaliDir, className |
smali_search |
smaliDir, pattern, optional flags / maxResults |
Q: Empty list_devices?
Check USB debugging, adb devices, pass serial if multiple.
Q: No business classes after static unpack?
Likely packed—use BlackDex or Frida.
Q: dex_to_smali failed?
Install Java; put baksmali jar in tools/ or set BAKSMALI_JAR.
Q: Frida jailed / version mismatch?
Keep frida-server and host frida major versions aligned; try 16.x.
Q: Where is output?
Default unpack-output/ (or DEX_OUT_DIR). Do not commit dumps.
Dự án này chỉ dành cho học tập, giảng dạy và nghiên cứu bảo mật được ủy quyền. Nghiêm cấm dùng cho tội phạm/bất hợp pháp (truy cập trái phép, crack, đạo nhái, tấn công, xâm phạm IP). Tác giả không chịu trách nhiệm về lạm dụng. Việc sử dụng đồng nghĩa chấp nhận điều khoản.
⚠️ Chỉ dùng cho học tập và giảng dạy. Không dùng cho hành vi bất hợp pháp, crack trái phép, xâm phạm bản quyền hay vượt bảo vệ của bên thứ ba. Tuân thủ pháp luật địa phương và điều khoản ứng dụng. Người dùng chịu trách nhiệm nếu lạm dụng.
MIT — see LICENSE.