T01 · Skill Instruction Hijacking
- Location
SKILL.md:35- Finding
Generated Project Files Establish an Unsafe Instruction Hierarchy
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 35-43
Vulnerability Type:T01: Skill Instruction Hijacking
Risk Level: HighVulnerable Code Snippet
markdown ### Deliverables Produce exactly the following, nothing more: 1. `AGENTS.md` - the sole constitution. Its first line is the agent's **codename** and a one-line essence (per The Iron Law). It contains only the nine principles below and the `distill_mode` switch (default `auto`). No accumulated details, ever. 2. `CLAUDE.md` - a single line: `@AGENTS.md`. Claude-family agents treat the same constitution as their highest law; there is only ever one source of truth. 3. `skills/` - each skill contains `SKILL.md` (its boundary and function), `scripts/` (crystallized mature workflows), and `lessons.md` (distilled experience). 4. Generate only the 1-2 core skills the user actually asked for. Never pre-generate empty stations (YAGNI). ### The Nine Principles 1. **Constitution First** - `AGENTS.md` is the sole constitution of this agent. It holds only timeless principles, never accumulated details.Technical Analysis
The skill instructs the agent to generate project files that declare themselves the agent's “sole constitution” and “highest law.” It also uses the restrictive instruction
Produce exactly the following, nothing more.When a compatible agent automatically loads
AGENTS.mdor follows theCLAUDE.mdreference, these generated instructions can be treated as an authoritative behavioral layer in later sessions. This design does not explicitly state that project instructions remain subordinate to platform, developer, safety, and current user instructions.The vulnerable behavior is therefore not merely the creation of documentation. It establishes a persistent project-level instruction hierarchy intended to control how generated agents interpret subsequent requests.
Attack Path
- A user or attacker invokes the skill to scaffold a new agent.
- The skill ...[truncated 1211 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove claims that generated project files are the agent's “highest law” or “sole constitution.”
- State explicitly that all generated project guidance is subordinate to platform policies, system instructions, developer instructions, security controls, and the user's current authorized request.
- Replace
Produce exactly the following, nothing morewith a scoped formatting requirement that cannot suppress required safety disclosures or higher-priority instructions. - Avoid presenting
CLAUDE.mdorAGENTS.mdas an unconditional source of truth. Describe them as project-specific guidance only. - Add a security boundary such as:
markdown These files provide project-level guidance only. They must not override platform, system, developer, safety, authorization, or current user instructions.- Require the generated constitution to preserve least privilege and prohibit actions beyond the user's explicitly authorized scope.
