SQL을 사용하여 Android APK 및 DEX 파일을 쿼리하고 클래스, 메서드, 문자열, smali 코드를 분석할 수 있도록 AI 에이전트에게 기능을 제공합니다.
다른 이름 LSPosed/dexsql-release, dexsql-release
- 스타
- 308
- Tools
- —
- 다운로드, 30일
- —
- 최신 버전
- 0.1.1
- 마지막 커밋
- 2026년 10월 25일
- 라이선스
- —
DexSQL MCP란?
DexSQL은(는) MCP server입니다. SQL을 사용하여 Android APK 및 DEX 파일을 쿼리하고 클래스, 메서드, 문자열, smali 코드를 분석할 수 있도록 AI 에이전트에게 기능을 제공합니다.
프로젝트 README에서 생성된 요약
DexSQL MCP server 정보
DexSQL은 AI 에이전트가 SQL을 사용하여 Android APK 및 DEX 파일에 대해 구조화된 분석을 수행할 수 있는 방법을 제공합니다. 사용자는 명령줄이나 MCP 연결을 통해 클래스, 메서드, 문자열, smali 코드와 같은 특정 요소를 쿼리할 수 있습니다. 이 도구는 수동 검사 없이 Android 바이너리에서 정밀한 데이터를 추출해야 하는 개발자와 보안 연구원을 위해 설계되었습니다.
서버는 로컬에서 실행되며 stdio MCP를 통해 Claude Desktop 또는 Codex와 같은 AI 클라이언트에 연결됩니다. Skills CLI를 사용하거나 macOS, Linux, Windows에서 실행 파일을 수동으로 구성하여 설치할 수 있습니다. DEX 파일을 직접 읽고 로드된 데이터셋을 재사용하기 때문에 메모리 사용량이 적고 반복적인 쿼리에 대해 낮은 지연 시간을 유지합니다. 사용자는 APK 경로를 제공하고 SQL 명령을 실행하여 호출 참조나 특정 문자열 값을 찾는 방식으로 상호작용할 수 있습니다.
활용 사례
- 1메서드 호출 관계 분석AI 에이전트가 특정 로그 메시지를 참조하는 메서드를 식별하고 해당 호출자 및 smali 코드를 가져올 수 있습니다.
- 2특정 API 엔드포인트 검색개발자는 SQL 쿼리를 사용하여 APK 내에서 특정 URL 문자열을 포함하는 모든 메서드를 찾을 수 있습니다.
- 3제3자 라이선스 정보 추출명령줄을 사용하여 애플리케이션의 모든 라이선스 고지 사항을 하나의 파일로 추출할 수 있습니다.
- 4멀티 파일 바이너리 분석 수행입력 플래그를 반복하여 여러 DEX 파일을 동시에 쿼리할 수 있습니다.
프로젝트의 README를 바탕으로 작성되었습니다. 모든 활용 사례는 해당 내용의 인용문과 대조하여 확인합니다.
자동 검사
2026년 11월 12일에 실행됨전체 보고서 →아직 인증되지 않았습니다. 서버는 80점 이상의 점수, 심각한 결함 없음, 그리고 검사에 충분한 데이터를 갖추어야 합니다. 검사 방식 · 점수를 높이기 위해 수정할 항목
- 소스 저장소 연결 및 접근 가능통과
- 오픈 소스 라이선스 (OSI)No license결함 발견
- 최근 1년 내 커밋 또는 릴리스통과
- 패키지 이름이 인기 패키지와 유사하지 않음검사되지 않음
- 원격 엔드포인트가 HTTPS 사용검사되지 않음
- 파괴적인 도구에 라벨 표시됨검사되지 않음
- 모델에 대한 숨겨진 지침 없음통과
- 패키지 및 해당 종속성에 중요한 보안 권고 없음검사되지 않음
README
GitHub에서 보기DexSQL
English | 简体中文
SQL for Android binaries.
Query classes, methods, strings, and call references in APK and DEX files. Connect it to an AI agent through MCP, or use it from the command line.
Playground · Documentation · Download · Install skill · Benchmarks
Why DexSQL?
AI agents can combine signatures, strings and call relationships in one SQL query across DEX files, returning just the structured results they need. Queries can be generated, refined and saved in scripts for reuse.
DexSQL reads DEX directly and reuses loaded datasets, supporting repeated queries with low latency and a small memory footprint. See the benchmarks for measurements.
The built-in MCP server connects directly to agents, with no GUI required.
flowchart LR
A["AI client"] -->|stdio MCP| D["DexSQL"]
D --> F["APK / DEX"]
A -->|stdio MCP| P["JADX-MCP · Python"]
P -->|HTTP| J["JADX GUI + plugin · JVM"]
J --> F
Use with an AI agent
DexSQL is listed in the official MCP Registry as org.lsposed/dexsql. Clients that install servers from the registry can add it directly, and Claude Desktop can open the dexsql.mcpb bundle from Releases. The bundle covers macOS, x86_64 Linux and x86_64 Windows; on other platforms, use the skill or manual setup below.
Install the setup skill with the Skills CLI:
npx skills add LSPosed/dexsql-release --skill install-dexsql
Then ask your agent to use install-dexsql to install DexSQL and configure its MCP connection. In Codex, invoke it as $install-dexsql.
The skill downloads a compatible binary from Releases, verifies its SHA-256 checksum, adds the MCP configuration, and checks the connection. It can also use a local executable. The command above installs the skill; the agent performs the actual setup when you invoke it.
Open Releases and choose the executable or archive that matches your operating system and CPU architecture. Check the selected release's assets and notes for availability and system requirements. Extract the archive if needed, then rename the executable to dexsql.exe on Windows or dexsql on macOS/Linux. On macOS/Linux, run chmod +x /path/to/dexsql.
Save LICENSE and LICENSE-AUXILIARY from the same Release alongside the executable, then register its absolute path. For Codex:
codex mcp add dexsql -- /absolute/path/to/dexsql mcp
For clients that use mcpServers JSON:
{
"mcpServers": {
"dexsql": {
"command": "/absolute/path/to/dexsql",
"args": ["mcp"]
}
}
}
On Windows, use dexsql.exe and escape backslashes in JSON, for example "D:\\Tools\\dexsql.exe". Reload the client's MCP connection if needed. See the Codex MCP documentation for client settings.
Once connected, try:
Open
/path/to/app.apk. Find methods referencing this log message, list their callers, and show the relevant Smali.
The server provides its schema and documentation through MCP resources. APK parsing runs locally and leaves the input unchanged. The AI client's settings determine which results are sent to its model.
Performance
A real MCP session
An AI agent analyzed Douyin 40.7.0 (343 MiB, 56 DEX files) through the DexSQL MCP server. We replayed its analysis goals on DexSQL 0.1.1 and six other tools: rasc (the Rust implementation of ASC), DexDec, ddc, the JADX API, garlic and droidsaw.
Opening the APK once and answering 10 goals took 0.71 s with DexSQL, 1.69 s with rasc, 16 s with DexDec and from 75 s to 449 s with the others. DexSQL pays 0.38 s to open the APK once per session; rasc has no open but rereads the APK in every step, so a session with a single question finishes sooner with rasc. Some tools did not show all expected evidence; those misses are still under review. See the replay report for every goal, each tool's interface, the method and the harness.
Fixed queries on QQ
Eight queries run against the same QQ 9.3.55 APK, about 372 MiB: class and method lookup, string references, direct and two-hop callers, and compound predicates. The comparison includes JADX, zinja-coder's JADX-MCP, ASC, DexDec, ddc, garlic, and droidsaw.
Startup time includes process launch, loading and preparation, and the first exact class lookup; values are medians of three runs. The OS file cache was not flushed.
Queries use the median of nine repeats across three prepared workflows. garlic restarts MCP for each call; that cost is included. droidsaw CLI uses three separate invocations, each including loading. Each query uses one linear chart starting at zero. Bars exceeding the axis limit are clipped, marked with an arrow and labeled with their actual time. Hatched bars mean the query did not finish within 60 seconds. Gray entries explain missing comparisons.
Direct and two-hop queries return 15 and 16 methods. Each compound query returns one method. Every completed, plotted result set is checked. The JADX native adapter reads metadata and DEX instructions directly; it does not decompile the whole APK to find references.
Memory uses a 50 ms polling wait across the whole process tree. Light bars cover the common load-and-class-lookup workflow; dark bars cover each tool's executed cases. Summed RSS can count shared pages more than once. Private committed memory and the footprint at readiness are also recorded.
DexDec's reference cache makes its repeated caller query faster than DexSQL in this run. droidsaw's MCP rejects the input under its fixed parse budget, so its CLI is plotted. See the report for first-query and preparation times, interface differences, SQL, result hashes and reproduction scripts.
CLI
dexsql query --input app.apk --sql "SELECT DISTINCT method FROM method_strings WHERE value = 'https://api.example.com'"
dexsql query --input app.apk --interactive
dexsql extract licenses --output THIRD_PARTY_NOTICES
dexsql --help
Repeat --input to query multiple files together. The same executable provides the CLI and MCP server.
License
DexSQL is closed-source software from LSPosed, licensed under the DexSQL Binary License 1.0. Personal and commercial use, integration, and binary redistribution are free under its terms.
The public installation skill, benchmark materials, and documentation use the MIT License.
Third-party materials retain their own licenses. Run dexsql extract licenses to view their notices.
DexSQL MCP 질문
DexSQL을 사용하여 APK 파일에서 무엇을 쿼리할 수 있나요?
APK 및 DEX 파일 내의 클래스, 메서드, 문자열 및 호출 참조를 SQL로 쿼리할 수 있습니다.
DexSQL이 원본 APK 파일을 수정하나요?
아니요, APK 파싱 프로세스는 로컬에서 실행되며 입력 파일을 변경하지 않습니다.
명령줄(command line)에서 DexSQL을 사용할 수 있나요?
네, 동일한 실행 파일이 MCP server와 쿼리 실행 및 라이선스 추출을 위한 CLI를 모두 제공합니다.