Back to skill

Security audit

Web App Template

Security checks for vulnerabilities and agentic risk

Overview

This web-app template is mostly disclosed, but it gives the agent broad autonomous memory, bootstrap, and heartbeat behavior that goes beyond a simple development template.

Install only if you want an opinionated agent workspace that keeps memory and performs proactive monitoring. Review and edit templates/AGENTS.md before use, especially BOOTSTRAP.md handling, memory files, heartbeat behavior, dependency updates, log/security-scan access, and any instruction that allows action without asking.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (1)

T01 · Skill Instruction Hijacking

Error
Location
templates/AGENTS.md:7
Finding

Untrusted Bootstrap Instruction Execution and Session Goal Hijacking

Content
View full analysis

Vulnerability Details

File Location: templates/AGENTS.md, lines 7-19
Vulnerability Type: Automatic execution of untrusted workspace instructions
Risk Level: High

Vulnerable Code

markdown
If `BOOTSTRAP.md` exists, that's your birth certificate. Follow it, figure out who you are, then delete it. You won't need it again.

## Every Session

Before doing anything else:

1. Read `SOUL.md` — this is who you are
2. Read `USER.md` — this is who you're helping
3. Read `memory/YYYY-MM-DD.md` (today + yesterday) for recent context
4. **If in MAIN SESSION** (direct chat with your human): Also read `MEMORY.md`
5. **Check for unresolved next actions** — scan last entry in `MEMORY.md` for any pending action items. If found, surface them immediately before anything else. Don't wait to be asked.

Don't ask permission. Just do it.

Technical Analysis

The workspace template instructs the agent to treat any local BOOTSTRAP.md file as an authoritative identity and behavior definition. It requires the agent to follow that file without validating its origin, trust level, or content, and then delete the file. This creates an instruction-hijacking boundary in which attacker-controlled project content can be interpreted as operational commands.

The directives “Before doing anything else” and “Don't ask permission. Just do it.” compound the issue by prioritizing workspace-derived instructions over the current user task and discouraging approval checks. Deleting BOOTSTRAP.md also removes the triggering artifact, reducing auditability and complicating incident investigation.

The same startup sequence automatically loads recent memory and surfaces stored action items. Although the template includes separate safeguards against sharing long-term memory in group contexts, it does not require safety or provenance validation before acting on bootstrap or memory-derived instructions.

Attack Path

  1. A user installs the Skill and copies its templates int ...[truncated 1860 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove the directive that automatically follows and deletes BOOTSTRAP.md.
  2. Treat all workspace Markdown files as untrusted contextual data rather than higher-priority instructions.
  3. Require explicit user approval before applying bootstrap content that changes identity, behavior, configuration, memory, or tool activity.
  4. Validate the bootstrap file's provenance and display its proposed changes to the user before acting on them.
  5. State explicitly that workspace content cannot override system instructions, developer instructions, current user requests, permission boundaries, or safety controls.
  6. Replace “Before doing anything else” and “Don't ask permission. Just do it.” with language requiring task relevance, safety validation, and approval for sensitive actions.
  7. Never delete bootstrap or instruction files automatically. Preserve them for review, or archive them with an audit record only after explicit user authorization.
  8. Validate memory-derived action items before execution. Stored items should be treated as historical context, not automatically trusted commands.
  9. Restrict automatic operations to read-only inspection inside the workspace. Require confirmation for command execution, dependency updates, external communications, deployment, credential access, and persistent state changes.
  10. Add tests or policy checks that use adversarial BOOTSTRAP.md and memory content to verify that untrusted files cannot supersede higher-priority instructions.
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Rogue AgentSelf-Modification, Session Persistence
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (17)

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The entire skill description is written in Japanese, and the document does not indicate that language selection is optional or that the skill is intended only for a Japanese-speaking audience. Under the policy, forcing a specific language without user opt-in is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · README.md (reported line 22)May include surrounding context.

テンプレートの使用

bash
# エージェントのワークスペースを作成
mkdir -p ~/.openclaw/workspace/my-web-app

# テンプレートをコピー
cp -r ~/.openclaw/workspace/skills/web-app-template/templates/* \

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · SKILL.md (reported line 45)May include surrounding context.

テンプレートの使用

bash
# エージェントのワークスペースを作成
mkdir -p ~/.openclaw/workspace/my-web-app

# テンプレートをコピー
cp -r ~/.openclaw/workspace/skills/web-app-template/templates/* \

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The natural-language content of the skill forces a specific language/locale throughout the manifest description and markdown instructions. Under the policy, this is a violation unless the skill offers user language choice or clearly documents that it is intended only for a Japanese-specific context.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The instruction to delete BOOTSTRAP.md after reading it directs a state-changing file operation without any user-facing warning or confirmation. Even if the file seems temporary, automatic deletion can destroy auditability, remove recovery information, or normalize destructive behavior early in agent execution.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

These instructions expand the skill from a web-app workspace template into persistent identity, memory loading, and session-behavior control. That scope creep can cause the agent to read unrelated files by default and carry forward sensitive personal context not required for web development, increasing privacy and least-privilege risks.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The instruction 'Don't ask permission. Just do it.' creates a broad default for autonomous action before the narrower safety constraints are applied. In practice, ambiguous proactive authority can lead the agent to access files, change state, or surface information without clear user authorization.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The file instructs the agent to read, write, and curate long-term and daily memory files containing personal context, despite the skill being presented as a web-app template. That mismatch creates unnecessary collection and retention of potentially sensitive user data and increases the chance of accidental disclosure across sessions or contexts.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · templates/AGENTS.md (reported line 76)May include surrounding context.

md
## Safety

- Don't exfiltrate private data. Ever.
- Don't run destructive commands without asking.
- `trash` > `rm` (recoverable beats gone forever)
- When in doubt, ask.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · templates/AGENTS.md (reported line 91)May include surrounding context.

md
**Ask first:**

- Deploying to production without approval
- Accessing external APIs without credentials
- Pushing to public repositories
- Running commands that affect system-wide state

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Heartbeat-driven monitoring and proactive outreach turn a template into an autonomous monitoring agent, which is outside the stated web-app setup purpose. This can trigger unsolicited reads of logs, memory files, or operational data and encourage ongoing background actions without explicit user intent.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
90% confidence
Finding

The section explicitly authorizes proactive work 'without asking,' including monitoring metrics, reviewing logs, checking security scans, updating dependencies, and editing memory. Those actions can read sensitive operational data or modify project state without user approval, which is risky in a general template and made more dangerous by the surrounding heartbeat automation.

Content

Scanner excerpt · templates/AGENTS.md (reported line 234)May include surrounding context.

md
- Nothing new since last check
- You just checked <30 minutes ago

**Proactive work you can do without asking:**

- Monitor performance metrics
- Review error logs

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The file’s operational instructions and guidance are presented only in Japanese, which can force a specific language on users or downstream agents. The policy allows locale constraints only when users are given a choice or when the restriction is explicitly documented and justified, neither of which appears here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

This markdown template includes core field labels and examples in Japanese, which steers usage toward a specific language without clearly offering the user a language choice in the template itself. Under the policy, forcing or defaulting to a specific language without opt-in can be a natural-language policy violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
93% confidence
Finding

This markdown file contains user-facing natural-language content entirely in Japanese, but it does not state that the skill is Japan-specific or that users can choose another language. Under the language/locale policy rule, forcing a specific language without opt-in can be a policy concern.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

Group-chat participation rules are unrelated to a web-app workspace template and expand the agent's behavioral scope into social interaction management. While lower impact than memory handling, this still increases the chance of context leakage or unintended participation in shared settings.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

The heartbeat guidance uses vague triggers like checking items '2-4 times per day' and reaching out when it has 'been >8h since you said anything,' which grants broad discretion for unsolicited intervention. Ambiguous autonomy can produce unnecessary monitoring, privacy-invasive reads, or noisy actions inconsistent with user expectations.

Content

No source excerpt is available for this finding.