[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-93300":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":15,"stars7d":16,"stars30d":16,"stars90d":15,"forks30d":15,"starsTrendScore":15,"compositeScore":17,"rankGlobal":9,"rankLanguage":9,"license":18,"archived":19,"fork":19,"defaultBranch":20,"hasWiki":19,"hasPages":19,"topics":21,"createdAt":9,"pushedAt":9,"updatedAt":33,"readmeContent":34,"aiSummary":35,"trendingCount":15,"starSnapshotCount":15,"syncStatus":14,"lastSyncTime":36,"discoverSource":37},93300,"morphe-ai","Paresh-Maheshwari\u002Fmorphe-ai","Paresh-Maheshwari","Morphe's AI-powered Android APK patching workspace — multi-agent pipeline for APK analysis, target hunting, patch writing & deployment.",null,"Shell",115,14,104,2,0,11,50.13,"GNU General Public License v3.0",false,"main",[22,23,24,25,26,27,28,29,30,31,32],"android","apk","morphe","morphe-patches","paresh-patches","patcher","patches","patching","reverse-engineering","smali","youtube","2026-07-22 04:02:08","# Morphe AI\n\nAI-powered Android APK patching workspace. Multi-agent pipeline that automates: APK analysis → decompilation → target hunting → patch writing → build & deploy.\n\nBuilt with [Kiro CLI](https:\u002F\u002Fkiro.dev), but the prompts, skills, and steering context are **model-agnostic** — adapt them to any AI coding assistant (Cursor, Copilot, Cline, Aider, Claude Code, etc.).\n\n**Author:** [Paresh Maheshwari](https:\u002F\u002Fgithub.com\u002FParesh-Maheshwari)\n**Repository:** [morphe-ai](https:\u002F\u002Fgithub.com\u002FParesh-Maheshwari\u002Fmorphe-ai)\n\n## Using with Other AI Models\n\nThe real value is in `.kiro\u002Fsteering\u002F` and `.kiro\u002Fprompts\u002F` — portable markdown files you can use with any AI tool:\n\n| Directory | Content |\n|-----------|---------|\n| `steering\u002Fcore\u002F` | Project overview, workspace layout |\n| `steering\u002Fpatching\u002F` | Patch writing guides, APIs, extension development |\n| `steering\u002Fbytecode\u002F` | Smali cheat sheet, fingerprinting, obfuscation guide |\n| `steering\u002Fpatterns\u002F` | Billing bypass, ad blocking, protection bypass patterns |\n| `steering\u002Fcommunity\u002F` | Patterns learned from 10+ community patch repos |\n| `steering\u002Fbuild\u002F` | Build commands, CLI reference, troubleshooting |\n| `prompts\u002F` | Agent role prompts (recon, decompiler, hunter, writer, deployer) |\n| `skills\u002F` | On-demand knowledge (tool reference, FAQ, examples) |\n\n**To use with your AI tool:**\n1. Feed the relevant steering `.md` files as context\u002Frules\n2. Use the prompts as system instructions\n3. Adapt the agent configs to your tool's format (e.g., `.cursorrules`, `.github\u002Fcopilot-instructions.md`)\n\n## Prerequisites\n\n- **Kiro CLI** installed and configured\n- **JDK 17** — `sudo apt install openjdk-17-jdk`\n- **Android RE tools:**\n\n| Tool | Purpose | Install |\n|------|---------|---------|\n| jadx | Decompile APK → Java source | `sudo apt install jadx` |\n| baksmali | Disassemble DEX → smali bytecode | `sudo apt install baksmali` |\n| smali | Assemble smali → DEX | `sudo apt install smali` |\n| apktool | Decode\u002Frebuild APK resources | `sudo apt install apktool` |\n| aapt | Read APK manifest\u002Fmetadata | `sudo apt install aapt` |\n| ripgrep (rg) | Fast regex search | `sudo apt install ripgrep` |\n| adb | Install APKs on device | `sudo apt install adb` |\n| dex2jar | Convert DEX → JAR | `sudo apt install dex2jar` |\n| apkid | Detect obfuscators\u002Fpackers | `uvx apkid` (no install needed) |\n| kaggle | Remote decompilation API | `pip install kaggle` |\n\nQuick install all:\n```bash\nsudo apt install -y openjdk-17-jdk jadx baksmali smali apktool aapt ripgrep adb dex2jar\npip install kaggle\n```\n\n## Quick Setup\n\n```bash\n# 1. Clone\ngit clone \u003Crepo-url> morphe && cd morphe\n\n# 2. Create .env with your secrets\ncp .env.example .env\n# Edit .env — add your KAGGLE_API_TOKEN\n\n# 3. Gradle auth (for morphe patcher dependencies)\nmkdir -p ~\u002F.gradle\ncat >> ~\u002F.gradle\u002Fgradle.properties \u003C\u003C EOF\ngpr.user = \u003Cyour-github-username>\ngpr.key = \u003Cgithub-pat-with-read:packages>\nEOF\n\n# 4. Clone your patches repo (folder must be named \"paresh-patches\")\n#    If you use a different name, update all references in .kiro\u002Fagents\u002F, .kiro\u002Fprompts\u002F, and AGENTS.md\ngit clone \u003Cyour-patches-repo> paresh-patches\n\n# 5. Setup CLI (downloads latest from GitHub)\n.\u002Fsetup-cli.sh\n\n# 6. Start Kiro\nkiro chat\n```\n\n## Environment Variables (.env)\n\n| Variable | Required | Where to get |\n|----------|----------|--------------|\n| `KAGGLE_API_TOKEN` | Yes | https:\u002F\u002Fkaggle.com\u002Fsettings → API → Create New Token |\n| `KAGGLE_KERNEL_ID` | Yes | Your Kaggle username + notebook name (e.g. `myuser\u002Fjadx-apk-decompiler`) |\n| `GITHUB_TOKEN` | Yes (for gradle) | GitHub → Settings → Developer → PAT with `read:packages` |\n\n## Kaggle Setup (Remote Decompilation)\n\nThe `jadx-decompile` script runs decompilation on Kaggle's free servers (4 cores, 28GB RAM) because jadx needs a lot of memory for large APKs.\n\n### How it works\n1. You provide a **direct download URL** of the APK (not a webpage link)\n2. Script generates a Kaggle notebook that downloads the APK and runs jadx\n3. Pushes notebook to Kaggle, waits for completion\n4. Downloads the decompiled output (zip) to your local machine\n\n### What it needs\n- A **direct APK download link** — the URL must directly download the file when opened\n  - ✅ `https:\u002F\u002Fdownload.apkmirror.com\u002Fwp-content\u002Fthemes\u002FAPKMirror\u002Fdownload.php?id=12345`\n  - ❌ `https:\u002F\u002Fwww.apkmirror.com\u002Fapk\u002Fcom.example\u002Fapp-name\u002F` (this is a page, not a download)\n- APKMirror download links expire after ~1 hour — use fresh links\n\n### Setup steps\n1. Create a free Kaggle account: https:\u002F\u002Fkaggle.com\n2. Go to Settings → API → Create New Token (gives you `KGAT_...` token)\n3. Create a **private** notebook: https:\u002F\u002Fkaggle.com\u002Fnotebooks → New Notebook\n   - Name it exactly: `jadx-apk-decompiler`\n   - Set to **private**\n   - Enable **internet access** in notebook settings\n4. Add to your `.env`:\n   ```\n   KAGGLE_API_TOKEN=KGAT_your_token_here\n   KAGGLE_KERNEL_ID=your-kaggle-username\u002Fjadx-apk-decompiler\n   ```\n\n### Usage\n```bash\n.kiro\u002Fjadx-decompile \"https:\u002F\u002Fdirect-download-url\" analysis\u002F\u003Capp>\u002F\n```\n\n## Workspace Structure\n\n```\nmorphe\u002F\n├── .env.example            # Template for secrets\n├── .gitignore              # Ignores secrets, binaries, large folders\n├── AGENTS.md               # Main orchestrator prompt\n├── LICENSE                 # Proprietary license\n├── README.md               # This file\n├── setup-cli.sh            # CLI download\u002Fbuild script\n└── .kiro\u002F\n    ├── agents\u002F             # 6 agent configs\n    ├── prompts\u002F            # Agent prompt files\n    ├── skills\u002F             # 13 on-demand skills\n    ├── steering\u002F           # 31 always-loaded context files\n    │   ├── core\u002F           # Project overview (morphe agent)\n    │   ├── build\u002F          # Build\u002FCLI reference (patch-deployer)\n    │   ├── patching\u002F       # Patch writing guides (patch-writer)\n    │   ├── bytecode\u002F       # Smali\u002Ffingerprinting (patch-writer + target-hunter)\n    │   ├── patterns\u002F       # Bypass patterns (target-hunter)\n    │   └── community\u002F      # Community patch analysis (target-hunter)\n    ├── settings\u002F           # LSP config\n    └── jadx-decompile      # Remote decompiler script\n\n# Created locally after setup (gitignored):\n├── .env                    # Your secrets\n├── Morphe.keystore         # APK signing key (export from Morphe Manager)\n├── morphe-cli.jar          # CLI binary (created by setup-cli.sh)\n├── paresh-patches\u002F         # Your patches repo clone\n└── analysis\u002F               # APK analysis work (per-app folders)\n    └── \u003Capp>\u002F\n        ├── apk\u002F            # Original APK files (created by apk-recon)\n        ├── notes\u002F          # Analysis findings (created by apk-recon)\n        ├── decompiled\u002F     # Java source from jadx (created by apk-decompiler)\n        ├── smali\u002F          # Bytecode from baksmali (created by apk-decompiler)\n        └── builds\u002F         # Patched APKs (created by patch-deployer)\n```\n\n## Agents\n\n### morphe (orchestrator)\n- **Trigger:** Default agent — always active\n- **What it does:** Checks pipeline state for any app and routes you to the correct specialist\n- **Tools:** All (bash, grep, glob, code, web search, knowledge)\n- **Context:** Core project overview\n- **Handles directly:** Quick builds, status checks, code searches, file reads\n\n### apk-recon\n- **Trigger:** \"Recon this APK\" or give it a file path\n- **What it does:** Identifies APK metadata — package name, version, protections, framework, APK type\n- **Tools:** aapt, apkid, unzip, file\n- **Input:** APK file path in project root\n- **Output:** `analysis\u002F\u003Capp>\u002Fnotes\u002Frecon.md` + organized `apk\u002F` folder\n- **Context:** APK analysis skill, apktool skill\n\n### apk-decompiler\n- **Trigger:** \"Decompile `\u003Capp>` — URL is `\u003Curl>`\"\n- **What it does:** Runs jadx remotely on Kaggle (28GB RAM), extracts smali from all DEX files\n- **Tools:** jadx-decompile script, baksmali, unzip\n- **Input:** App name + direct APK download URL\n- **Output:** `analysis\u002F\u003Capp>\u002Fdecompiled\u002F` (Java) + `analysis\u002F\u003Capp>\u002Fsmali\u002F` (bytecode)\n- **Context:** APK analysis skill, jadx skill, tool reference\n\n### target-hunter\n- **Trigger:** \"Find targets for `\u003Capp>` — looking for `\u003Cpremium\u002Fads\u002Fgates>`\"\n- **What it does:** Searches decompiled code for billing SDKs, ads, feature gates. Verifies every finding against smali bytecode. Documents fingerprint strategies.\n- **Tools:** rg (ripgrep), glob, code (LSP), thinking\n- **Input:** App name + what to find\n- **Output:** `analysis\u002F\u003Capp>\u002Fnotes\u002Fpremium-bypass.md`, `ad-removal.md`, etc.\n- **Context:** Billing\u002Fad\u002Fprotection bypass patterns, community patch analysis, smali\u002Ffingerprinting guides\n\n### patch-writer\n- **Trigger:** \"Write patches for `\u003Capp>`\"\n- **What it does:** Reads target findings, cross-checks against smali, writes Kotlin fingerprints + patch code, builds and verifies\n- **Tools:** rg, glob, code (LSP), gradle, thinking\n- **Input:** App name (reads notes automatically)\n- **Output:** `.kt` files in `paresh-patches\u002Fpatches\u002Fsrc\u002F...\u002F`\n- **Context:** Patch development guides, patcher APIs, bytecode utilities, real patch examples, advanced techniques\n\n### patch-deployer\n- **Trigger:** \"Build and test `\u003Capp>`\"\n- **What it does:** Builds patches with gradle, patches APK with morphe-cli, installs via ADB, reports results\n- **Tools:** gradle, morphe-cli, adb, git\n- **Input:** App name + action (build\u002Ftest\u002Fdeploy)\n- **Output:** `analysis\u002F\u003Capp>\u002Fbuilds\u002F\u003Capp>_patched.apk`\n- **Context:** Build\u002FCLI reference, troubleshooting guide\n\n## Pipeline\n\n```\n1. RECON        → apk-recon identifies the APK\n2. DECOMPILE    → apk-decompiler runs jadx + baksmali\n3. HUNT         → target-hunter finds patchable targets\n4. WRITE        → patch-writer creates Kotlin patches\n5. BUILD+DEPLOY → patch-deployer builds, patches APK, installs\n```\n\nJust give the morphe agent an app name — it checks state and tells you which agent to switch to next.\n\n## Usage Examples\n\n```\n# Start fresh with a new APK\n> I have a new APK for truecaller\n\n# Continue work on existing app\n> truecaller\n\n# Quick tasks (morphe handles directly)\n> build patches\n> list patches\n> search for \"isPremium\" in truecaller\n> what's the status of all apps?\n```\n\n## Customization\n\n### Adding a new app\n1. Download APK to project root\n2. Tell morphe agent: \"New APK for `\u003Capp>`\"\n3. Follow the pipeline\n\n### Modifying agent behavior\n- Edit prompts in `.kiro\u002Fprompts\u002F`\n- Edit configs in `.kiro\u002Fagents\u002F`\n- Add steering files to `.kiro\u002Fsteering\u002F\u003Ccategory>\u002F`\n\n### Adding new steering context\nPlace `.md` files in the appropriate category folder. They auto-load for agents that reference that folder.\n\n### Updating the jadx-decompile script\nIf you change your Kaggle username, update `KAGGLE_KERNEL_ID` in your `.env` file.\n\n## Signing Key\n\nThe `Morphe.keystore` is used to sign all patched APKs. Both the Morphe Manager app (phone) and CLI must use the **same keystore** so patched APKs can update each other.\n\n### Export from Morphe Manager (recommended)\n1. Open Morphe Manager on your phone\n2. Go to Settings → Export keystore\n3. Transfer the exported `.keystore` file to this project root\n4. Rename to `Morphe.keystore`\n\nThis ensures phone-patched and CLI-patched APKs share the same signature — you can install updates from either without uninstalling.\n\n### Generate new keystore (if starting fresh)\n```bash\nkeytool -genkey -v -keystore Morphe.keystore -alias Morphe \\\n  -keyalg RSA -keysize 2048 -validity 10000 \\\n  -storepass morphe -keypass morphe\n```\n\nThen import this keystore into Morphe Manager: Settings → Import keystore.\n\n### Usage\nThe CLI always uses this keystore:\n```bash\njava -jar morphe-cli.jar patch -p patches.mpp --keystore Morphe.keystore -f input.apk\n```\n\n## Troubleshooting\n\n| Issue | Fix |\n|-------|-----|\n| Gradle auth fails | Check `~\u002F.gradle\u002Fgradle.properties` has `gpr.user` + `gpr.key` |\n| jadx-decompile fails | Check `.env` has `KAGGLE_API_TOKEN`, verify with `kaggle kernels list` |\n| Fingerprint doesn't match | App version changed — re-run target-hunter to verify smali |\n| Build fails | Check error in patch-deployer output — it gives exact file + line |\n| ADB not found | `sudo apt install adb` or connect device |\n| Agent gives wrong answer | Check steering files are loading: `\u002Fcontext show` in Kiro |\n\n## Community Patch Repos (Reference)\n\nThe steering files in `.kiro\u002Fsteering\u002Fcommunity\u002F` contain patterns learned from these repos:\n\n| Repo | Focus | Patterns |\n|------|-------|----------|\n| [morphe-patches (hoo-dles)](https:\u002F\u002Fgithub.com\u002Fhoo-dles\u002Fmorphe-patches) | Various apps | Method injection, signature spoof, extension-based ad skip |\n| [De-ReVanced](https:\u002F\u002Fgithub.com\u002FRookieEnough\u002FDe-ReVanced) | YouTube\u002FMusic | Device ID spoofing, signature bypass |\n| [revanced-patches (anddea)](https:\u002F\u002Fgithub.com\u002Fanddea\u002Frevanced-patches) | Extended YouTube | Advanced ad blocking, SponsorBlock |\n| [piko](https:\u002F\u002Fgithub.com\u002Fcrimera\u002Fpiko) | Instagram | Entity patterns, JSON field replacement, feed filtering |\n| [patcheddit](https:\u002F\u002Fgithub.com\u002Fwchill\u002Fpatcheddit) | Reddit | Client ID spoofing, OAuth override, matchAll() bulk replace |\n| [adobo](https:\u002F\u002Fgithub.com\u002Fjkennethcarino\u002Fadobo) | Universal ad blocking | Per-SDK ad removal (AdMob, Unity, AppLovin, IronSource) |\n| [AmpleReVanced](https:\u002F\u002Fgithub.com\u002FAmpleReVanced\u002Frevanced-patches) | Spotify | Hex patching native libs, protocol spoofing |\n| [morphe-meta-patches](https:\u002F\u002Fgithub.com\u002FMeridianFresco\u002Fmorphe-meta-patches) | Facebook\u002FMeta | Sponsored content removal, story filtering |\n| [binarymend](https:\u002F\u002Fgithub.com\u002Fbinarymend\u002Fmorphe-patches) | Various apps | Telemetry blocking, bulk analytics disable |\n\n## Contributing\n\n**PRs welcome!** This project benefits from community knowledge. You can help by:\n\n- 🧠 **Improving prompts** — better instructions, fewer hallucinations, more accurate patches\n- 📚 **Adding steering context** — document new bypass patterns, SDK techniques, or app architectures\n- 🛠️ **Adding skills** — new on-demand knowledge files for specific tools or workflows\n- 🤖 **Adapting to other AI tools** — configs for Cursor, Copilot, Cline, Aider, etc.\n- 📝 **Documenting patterns** — analyzed a new app? Share the technique\n- 🐛 **Fixing issues** — found a wrong instruction or bad fingerprint pattern? Fix it\n\n### How to contribute\n\n1. Fork this repo\n2. Create a branch: `git checkout -b feat\u002Fyour-improvement`\n3. Make your changes (add\u002Fedit files in `.kiro\u002Fsteering\u002F`, `.kiro\u002Fprompts\u002F`, `.kiro\u002Fskills\u002F`)\n4. Open a PR with a clear description of what you improved\n\n### Contribution ideas\n\n- Add patterns for new billing SDKs (Adapty, Qonversion, Glassfy)\n- Add patterns for new ad SDKs (InMobi, IronSource, Chartboost)\n- Improve fingerprint debugging guidance\n- Add support files for other AI tools (`.cursorrules`, `.github\u002Fcopilot-instructions.md`)\n- Document Flutter\u002FReact Native patching techniques\n- Add more real-world patch examples\n\n## License\n\nCopyright © 2026 Paresh Maheshwari. All rights reserved. See [LICENSE](LICENSE).\n","Morphe AI 是一个面向 Android APK 逆向与自动化补丁开发的工作空间，基于多智能体协作流程实现 APK 分析、目标定位、Smali 补丁编写及构建部署的端到端自动化。项目采用模型无关设计，核心由可移植的 Markdown 格式引导文档（steering）和角色化提示词（prompts）构成，兼容 Kiro、Cursor、Copilot 等主流 AI 编程助手。依赖标准 Android 逆向工具链（jadx、apktool、baksmali\u002Fsmali 等），适用于安全研究、应用功能定制（如广告屏蔽、付费绕过）、教学演示等需高频手动 patch 的场景。","2026-07-15 02:30:12","CREATED_QUERY"]