moai-adk: Skill for Claude Code

.claude/skills/moai-ref-llm-security/SKILL.md

moai-ref-llm-security is a skill for Claude Code from modu-ai/moai-adk. It costs 159 tokens per session (3,898 once invoked), scanned B, original, Apache-2.0.

A defensive security reference for applications and agents that use large language models, including chat tools, retrieval systems, and MCP servers.

In plain words
What is it for?
Use it when reviewing or building LLM systems, to address prompt injection, unsafe tool calls, poisoned data, output validation, and security governance.
Why use it?
It explains how untrusted prompts, documents, tool results, and model outputs can introduce security risks and how to detect or prevent them.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

This is modu-ai/moai-adk's own configuration. It tells Claude Code how to work on moai-adk itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything moai-adk configures →

About the project

MoAI-ADK is a Go-based harness that organizes and verifies Claude Code work across planning, implementation, synchronization, and review stages. Developers use it to structure agentic coding tasks, apply quality gates, and route work across language models, while the catalogue entries extend its workflow with skills, hooks, commands, MCP servers, instructions, and settings.

modu-ai/moai-adk · 1,204 stars · on GitHub · adk.mo.ai.kr

Reuse

Borrowing it

Nothing to install: this file belongs to modu-ai/moai-adk. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/modu-ai/moai-adk/main/.claude/skills/moai-ref-llm-security/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/modu-ai/moai-adk

Made for: Claude Code.

Wrote 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.

agentmods badge for moai-ref-llm-security

README.md
[![agentmods](https://agentmods.dev/badge/skills/modu-ai/moai-adk/moai-ref-llm-security/github.svg)](https://agentmods.dev/skills/modu-ai/moai-adk/moai-ref-llm-security)
Your own site
<a href="https://agentmods.dev/skills/modu-ai/moai-adk/moai-ref-llm-security"><img src="https://agentmods.dev/badge/skills/modu-ai/moai-adk/moai-ref-llm-security/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.

agentmods 80×15 button for moai-ref-llm-security

Your own site · 80×15
<a href="https://agentmods.dev/skills/modu-ai/moai-adk/moai-ref-llm-security"><img src="https://agentmods.dev/badge/skills/modu-ai/moai-adk/moai-ref-llm-security.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 159 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,898 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 8 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Prompt Injection · line 77
    This pattern attempts to override system instructions or ignore safety constraints. Without LLM analysis, manual review is recommended.
    Fix: Remove or rewrite any text that instructs the agent to ignore prompts, override safety rules, or trust unverified content. Ensure skill content cannot be injected to alter agent behavior.
  • high Memory Poisoning · line 169
    Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.
    Fix: Protect agent memory and state from modification by untrusted content. Use read-only memory for critical instructions and validate all state changes.
  • high Memory Poisoning · line 203
    Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.
    Fix: Protect agent memory and state from modification by untrusted content. Use read-only memory for critical instructions and validate all state changes.
  • high Prompt Injection · line 246
    Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
    Fix: Audit all comments and invisible characters. Remove any instructions that direct the agent to perform unauthorized actions. Use plain, reviewable content.
  • high Prompt Injection · line 264
    Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
    Fix: Audit all comments and invisible characters. Remove any instructions that direct the agent to perform unauthorized actions. Use plain, reviewable content.
  • high Prompt Injection · line 277
    Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
    Fix: Audit all comments and invisible characters. Remove any instructions that direct the agent to perform unauthorized actions. Use plain, reviewable content.
  • medium Excessive Agency · line 66
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
  • medium Excessive Agency · line 283
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00159 $0.03898
Opus 5 $0.00079 $0.01949
Sonnet 5 $0.00032 $0.00780
Haiku 4.5 $0.00016 $0.00390

Measured 10d ago against content hash 0d8ec550434e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade B, and why

moai-ref-llm-security scanned grade B with 1 finding 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 10d 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.

Instruction-override phrasingmediumPrompt injection

Text telling the model to disregard its earlier instructions or safety rules is the shape of a prompt injection, whoever wrote it.

| LLM01 | Prompt Injection | Can external text override system instructions? | Instruction-hierarchy enforcement, input/output screening, content isolation |

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

.claude/skills/moai-ref-llm-security/SKILL.md · 290 lines

How it starts

The opening of the file, as written. The whole thing — 290 lines — stays where its author put it; the contents beside it link to each section on GitHub.

LLM / AI Defensive Security Reference

Defensive practitioner reference for hardening LLM-backed applications and agents. Every section is framed as defense, hardening, detection, or verification — it describes the misconfiguration, how to detect it, and how to prevent it, never how to exploit it. Cross-domain web-app vulnerabilities live in moai-ref-owasp-checklist; API design lives in moai-ref-api-patterns.

Target Use

Apply when reviewing or building an LLM-backed system — a chat product, a retrieval-augmented application, an autonomous agent, or an MCP server. The material assumes an untrusted-input threat model: any text the model reads (user turns, retrieved documents, tool results, file contents) may carry adversarial instructions, and any text the model emits may be acted on downstream.

Trust Boundaries in an LLM System

The core defensive insight: an LLM does not distinguish "data" from "instructions" the way a parser does. Treat every text channel that reaches the model as a boundary where adversarial instructions can enter.

Channel Entry risk Primary defense
End-user prompt Direct prompt injection Instruction-hierarchy enforcement, input screening
Retrieved documents (RAG) Indirect prompt injection Provenance tagging, content isolation, retrieval allowlist
Tool / function results Injected instructions in tool output Treat tool output as untrusted data, re-validate before re-prompting
System / developer prompt Leakage, override Minimize secrets in prompt, assume prompt is recoverable
Model output Improper downstream handling Schema validation, encoding, never auto-execute raw output
Training / fine-tuning data Poisoning Data lineage, provenance verification, canary detection

OWASP LLM Top 10 — Defensive Mapping

The OWASP Top 10 for LLM Applications (2025 edition) is the canonical risk index for LLM systems. Each row below states the risk, the defensive check, and the hardening control. Citations are for defensive correlation only.

Read the full file on GitHub · 290 lines

Changes

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.

  1. 10d ago First seen · 290 lines · 159 tokens per session scan B 0d8ec550434e

Subscribe to this mod's changes

moai-ref-llm-security is a skill published in the GitHub repository modu-ai/moai-adk (1,204 stars, last pushed today), licensed Apache-2.0. It adds 159 tokens to every session and 3,898 once invoked, about $0.0008 per session on Opus 5. A static security scan graded it B with 1 finding (instruction-override phrasing). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

code-reviewer

Automatic code quality and best practices analysis. Use proactively when files are modified, saved, or committed. Analyzes code style, patterns, potential bugs, and security basics. Triggers on file changes, git diff, code edits, quality mentions.

alirezarezvani/claude-code-tresor · 54 tokens

test-generator

Automatically suggest tests for new functions and components. Use when new code is written, functions added, or user mentions testing. Creates test scaffolding with Jest, Vitest, Pytest patterns. Triggers on new functions, components, test requests, testing mentions.

alirezarezvani/claude-code-tresor · 55 tokens

api-documenter

Auto-generate API documentation from code and comments. Use when API endpoints change, or user mentions API docs. Creates OpenAPI/Swagger specs from code. Triggers on API file changes, documentation requests, endpoint additions.

alirezarezvani/claude-code-tresor · 48 tokens

readme-updater

Keep README files current with project changes. Use when project structure changes, features added, or setup instructions modified. Suggests README updates based on code changes. Triggers on significant project changes, new features, dependency changes.

alirezarezvani/claude-code-tresor · 49 tokens

security-auditor

Continuous security vulnerability scanning for OWASP Top 10, common vulnerabilities, and insecure patterns. Use when reviewing code, before deployments, or on file changes. Scans for SQL injection, XSS, secrets exposure, auth issues. Triggers on file changes, security mentions, deployment prep.

alirezarezvani/claude-code-tresor · 63 tokens

version-check

Recommend which Claude Code version to run, or whether to update. Use when asked which Claude Code version is best/safe, whether to update now, whether a recent release is buggy, or what changed since the installed version.

ykdojo/claude-code-tips · 48 tokens