Log inGet a Demo

agent-factory

High · Risk 70

The skill is critically vulnerable to indirect prompt injection and path traversal, allowing attackers to execute unauthorized code by injecting malicious instructions into dynamically generated, unverified sub-agent configurations.

Findings (10)

Content Injection

High

targets Perception

2 findings
#1Worker prompt includes attacker-controllable task namehighprompt injection88% confidence

The dispatch prompt passed to spawned sub-agents embeds `task['name']` and `task['id']` directly without escaping. If the DAG originates from an external or user-controlled source, these fields can carry injected instructions that redirect the worker agent's behavior.

dispatch_prompt = f"""You are worker agent {worker_id}.\n\nYour task: {task['name']} (Task {task['id']})"""
#2Template injection via unvalidated task fieldshighprompt injection90% confidenceline 79

Task fields like `task['name']`, `task['acceptance']`, and `task['task_instructions']` are substituted directly into worker skill templates without sanitization. An attacker-controlled task node (e.g., from a malicious DAG or message bus) can inject arbitrary instructions into the spawned worker's SKILL.md.

worker_skill = worker_skill.replace(placeholder, value) ... '{acceptance}': task.get('acceptance', 'Complete the task as specified')

Semantic Manipulation

Medium

targets Reasoning

1 finding
#1Implicit trust in task definitionsmediumsocial engineering75% confidence

The system assumes the 'task' dictionary is trusted, but it is used to populate instructions for sub-agents, creating a vector for indirect prompt injection if the DAG/task source is compromised.

worker_skill = worker_skill.replace('{task_instructions}', task['task_instructions'])

Behavioural Control

High

targets Action

5 findings
#1Dynamic code generation via template injectionhighcommand execution85% confidenceline 79

The skill dynamically generates and writes new SKILL.md files based on task input, allowing for arbitrary instruction injection into the sub-agent's behavior.

worker_skill = worker_skill.replace(placeholder, value)
#2Unrestricted sub-agent autonomyhighautonomy abuse90% confidenceline 118

The dispatch prompt explicitly instructs sub-agents to 'Execute autonomously. Do NOT wait for user input,' which bypasses human oversight for potentially sensitive file modifications.

Execute autonomously. Do NOT wait for user input.
#3Ephemeral skill files written to disk without integrity checkmediumtool poisoning75% confidence

Worker SKILL.md files are written to a predictable path under `$CLAUDE_PLUGIN_ROOT/skills/workers/{worker_id}/` with no integrity verification. A race condition or path traversal in `worker_id` (derived from task input) could allow overwriting existing skill files or injecting content into the skill directory.

worker_skill_path = f"${CLAUDE_PLUGIN_ROOT}/skills/workers/{worker_id}/SKILL.md" ... write_file(worker_skill_path, worker_skill)
#4Sub-agent spawning instructions detected — may create agents with attacker-controlled promptsmedium100% confidenceline 13

Sub-agent spawning instructions detected — may create agents with attacker-controlled prompts

Spawn Worker
#5Potential for path traversal in file operationsmediumresource abuse70% confidenceline 99

The worker_id is derived directly from task['id'] and used to construct file paths without sanitization, potentially allowing a malicious task definition to escape the intended directory.

worker_skill_path = f"${CLAUDE_PLUGIN_ROOT}/skills/workers/{worker_id}/SKILL.md"

Human-in-the-Loop

Medium

targets Human Overseer

1 finding
#1Autonomous execution directive suppresses human oversightmediumapproval fatigue85% confidenceline 118

Every spawned worker is explicitly instructed to 'Execute autonomously. Do NOT wait for user input.' This systematically removes human-in-the-loop checkpoints across all dynamically created agents, preventing any oversight of worker actions.

Execute autonomously. Do NOT wait for user input.

Hygiene

Info

targets Packaging & Manifest

1 finding
#1Missing licenseinfo100% confidence

Skill does not specify a license field. Specifying a license helps users understand usage terms.