T01 · Skill Instruction Hijacking
- Location
SKILL.md:315- Finding
Untrusted Upstream Instructions Are Treated as Authoritative Prompt Directives
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 315–318
Vulnerability Type: Indirect prompt injection through untrusted configuration fields
Risk Level: MediumRelevant Skill Text (English translation):
markdown > **Additional instruction fields (must be followed strictly):** > `--details` and `--angle` are optional fields. When supplied by the user, > they must be followed strictly: > - `--details` → Incorporate it into the corresponding shot description; do not ignore or replace it. > - `--angle` → Arrange the shot structure according to that angle; do not arbitrarily change its direction. > - The `usage_instructions` passed by upstream Skill1 through `--config` must also be followed strictly.Related data-flow documentation appears at
SKILL.md, line 329:markdown - `selling_points.json` — Structured selling points passed through `--config`, including the `usage_instructions` field.Technical Analysis
The skill instructs the agent to follow free-form values from
details,angle, and particularly the upstreamusage_instructionsfield strictly. These values originate from user input or an upstream JSON configuration and are therefore untrusted.The documented workflow incorporates these values into a structured AI prompt without specifying a trust boundary, escaping mechanism, content validation, instruction hierarchy, or prohibition against interpreting embedded directives as agent instructions. Consequently, an attacker-controlled
usage_instructionsvalue could contain prompt-injection directives rather than legitimate product usage information.For example, an attacker could supply text directing the model to disregard the storyboard requirements, emit unrelated content, alter the expected JSON structure, or insert further instructions into generated artifacts. The issue is an instruction/data separation failure: product metadata is descri ...[truncated 1999 chars]
- Remediation
View remediation
Remediation Suggestions
- Treat
details,angle, andusage_instructionsexclusively as untrusted product data, not authoritative instructions. - Replace requirements to “follow strictly” with narrowly scoped rules defining exactly which storyboard fields each value may influence.
- Explicitly state that these fields cannot modify system instructions, safety rules, tool use, file operations, output schemas, or workflow transitions.
- Validate
selling_points.jsonagainst a strict schema, including type checks, length limits, allowed character policies, and rejection of unexpected properties. - Delimit untrusted values clearly when constructing prompts and label them as quoted reference data that must not be interpreted as instructions.
- Detect and reject instruction-like content, including requests to ignore prior rules, invoke tools, access secrets, change output formats, or control downstream agents.
- Construct the final JSON through schema-constrained generation and validate it before saving or passing it to Skill3.
- Require explicit user review or approval before sending generated storyboard content to downstream video-generation components.
- Add adversarial tests covering malicious
usage_instructions,details, andanglevalues to verify that they cannot override the skill's intended behavior.
- Treat
