Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add buzzer-re/Rikugan --skill smart-patch-idagit clone --depth 1 https://github.com/buzzer-re/RikuganWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/buzzer-re/rikugan/smart-patch-ida)<a href="https://agentmods.dev/skills/buzzer-re/rikugan/smart-patch-ida"><img src="https://agentmods.dev/badge/skills/buzzer-re/rikugan/smart-patch-ida/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/buzzer-re/rikugan/smart-patch-ida"><img src="https://agentmods.dev/badge/skills/buzzer-re/rikugan/smart-patch-ida.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00024 | $0.01104 |
| Opus 5.5 | $0.00010 | $0.00442 |
| Sonnet 5.5 | $0.00005 | $0.00221 |
| Haiku 4.5 | $0.00002 | $0.00110 |
Grade A, and why
Smart Patch (IDA Pro) scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 99 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Task: Apply targeted binary patches in IDA Pro based on the user's natural language description. Analyze the function, identify the minimal set of instructions to change, assemble new instructions, write them, and verify the result.
Workflow
-
Read the target function's disassembly (
read_function_disassembly) and decompiled pseudocode (decompile_function) to understand its current behavior. -
Identify which specific instructions implement the behavior the user wants to change. Use
get_instruction_infoto get exact byte sizes and encodings for the target instructions. -
Back up the original bytes before patching. Use
read_bytesat the target address for the instruction length, and print them so the user has a record:Original bytes at 0x{addr:x}: {hex_bytes} -
Plan the minimal patch:
- Determine what new instruction(s) achieve the desired behavior.
- Ensure the new instructions fit within the original byte boundaries.
- If new instructions are shorter, the remaining bytes MUST be filled with NOPs.
- Verify branch targets and relative offsets are correct for the patch address.
-
Patch using
execute_pythonwith IDA's byte-patching API:import ida_bytes, idc # Option A: manual opcode (for simple patches like branch inversion) ida_bytes.patch_bytes(0xADDR, bytes([0x75])) # JNZ instead of JZ # Option B: use keystone assembler (if installed) import keystone ks = keystone.Ks(keystone.KS_ARCH_X86, keystone.KS_MODE_64) encoding, _ = ks.asm("jg 0x401300", 0x401248) ida_bytes.patch_bytes(0x401248, bytes(encoding)) # NOP padding remaining = original_size - len(encoding) if remaining > 0: ida_bytes.patch_bytes(0x401248 + len(encoding), bytes([0x90] * remaining)) print(f"Patched at 0x401248") -
Verify with
redecompile_function— confirm the decompiled output reflects the desired behavior change. If it doesn't match, revert by writing back the original bytes and try a different approach. -
Report — If called from
/modify, you MUST call:exploration_report(category="patch_result", address=..., summary="Patched X: old → new", original_hex="...", new_hex="...", evidence="redecompile confirms...") -
Annotate each patched address with
set_commentexplaining what was changed and why.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 99 lines · 24 tokens per session scan A 0988963f0ea2
Smart Patch (IDA Pro) is a skill published in the GitHub repository buzzer-re/Rikugan (690 stars, last pushed 8d ago), licensed MIT. It adds 24 tokens to every session and 1,104 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
create-patch
Create or continue an authorized Morphe Android patch from an APK and requested change. Use when the user wants the complete workflow: APK reconnaissance, decompilation, target discovery, smali verification, patch implementation, and local validation.
validate-patch
Build, list, and locally apply Morphe patches to verify registration and fingerprint matching. Use after patch source exists or when diagnosing build and match failures.
find-patch-targets
Find Morphe patch targets in decompiled Android source and verify each target against exact smali bytecode. Use after decompiled source and smali exist.
write-patch
Implement an approved Morphe patch design from smali-verified findings. Use only after target evidence exists and the user has approved the proposed source changes.
python-large-file-patch-{{AGENT_NAME_LOWER}}
How to patch large Python files in the {{AGENTNAME}} codebase. Covers the dual-file layout (runtime /.{{AGENTNAMELOWER}}/agent/ vs source /.{{AGENTNAMELOWER}}/source/{{AGENTNAMELOWER}}-agent/), diagnose-fallback when direct patch fails, and the copy-sync protocol to keep both copies aligned.
aida-audit-guide
Analysis Skill Guide for AIDA MCP.