T01 · Skill Instruction Hijacking
- Location
SKILL.md:2- Finding
Dynamic Behavioral Profile Can Hijack Agent Instructions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 2-3 and 16-34
Vulnerability Type: Dynamic instruction injection through an unaudited behavioral profile
Risk Level: HighVulnerable Code
yaml name: emulo description: Load the user's Emulo profile, mined from their local Claude Code, Codex, and OpenCode session logs, so you work like them instead of a cold start. Use before working on their task.markdown # Emulo profile Load the user's Emulo working profile so you act like them, not a cold start. Emulo mines the user's own AI coding sessions (Claude Code, Codex, Cursor, Copilot) into a `you.md` working profile: their laws, their taste, their voice, and the failure modes they want you to protect them from. ## Use this before working on their task Run the profile loader and read what it returns before you plan or edit: \`\`\` emulo --install you.md --target agents \`\`\` Or load it directly through the MCP server: \`\`\` uvx emulo mcp \`\`\`Technical Analysis
The skill directs the agent to load a dynamically generated profile before planning or editing. The profile is generated from mutable historical session logs and is explicitly intended to supply behavioral “laws,” voice rules, preferences, and failure-handling instructions.
Because neither the generated
you.mdfile nor the MCP response is included in the reviewed project, its effective instructions cannot be audited with the skill. Treating this external content as authoritative agent instructions creates a prompt-injection boundary violation. Malicious or poisoned text in historical logs could be transformed into profile rules and subsequently influence the agent’s goals, tool use, or safety decisions.The risk is amplified by wording that tells the agent to “act like” the profile and to read it before doing any task-related planning.
Attack Path
- An attacker causes crafted instructions to appear in a local Claude Code, Codex, Cursor, Copilo ...[truncated 969 chars]
- Remediation
View remediation
Remediation Suggestions
- Treat all generated profiles and MCP responses as untrusted preference data, not executable instructions.
- Define a strict schema limited to non-authoritative preferences such as formatting style, naming conventions, and explicitly enumerated options.
- Reject imperative instructions, tool directives, embedded prompts, shell commands, and content claiming to override system, developer, or user instructions.
- State explicitly that profile content cannot modify safety policies, authorization boundaries, or the current user’s task.
- Apply provenance tracking and robust prompt-injection filtering to content extracted from session logs.
- Present the generated profile to the user for review and approval before the agent consumes it.
- Load profiles only with explicit consent and only after the agent has established the current task’s authorization boundaries.
- Run profile parsing in a sandbox and return structured data rather than free-form instruction text.
