Back to skill

Security audit

Council Builder

Security checks for vulnerabilities and agentic risk

Overview

The skill matches its council-building purpose, but it needs review because it writes durable agent instructions from conversation-derived learnings and its setup script does not contain agent names safely.

Review this before installing. Use it only with trusted agent names, require a separate opt-in before scanning existing memory or workspace history, and review every proposed change to SOUL.md, AGENTS.md, TOOLS.md, MEMORY.md, and shared learnings before it is saved. Do not allow secrets, credentials, private personal data, or external-document instructions to be stored as learnings or promoted into agent behavior.

Vulnerability Patterns
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • 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
Findings (2)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/init-council.sh:94
Finding

Path Traversal and Configuration Injection Through Unvalidated Agent Names

Content
View full analysis
"$AGENT_DIR/gotchas.md" << EOF # Gotchas — $AGENT Known pitfalls. Read this before major tasks. --- EOF fi # Initialize config.json if [ ! -f "$AGENT_DIR/config.json" ]; then cat > "$AGENT_DIR/config.json" << EOF { "agent_name": "$AGENT", "setup_complete": false, "preferences": {}, "api_keys_ref": [], "custom_settings": {} } EOF fi ``` ### Technical Analysis The script accepts agent names from positional command-line arguments and uses them directly to construct filesystem paths. Shell quoting prevents ordinary shell command injection, but it does not prevent path traversal. An agent name containing components such as `../` can cause `AGENT_DIR` to resolve outside the intended `workspace/agents/` directory. The script then creates directories and predictable Markdown and JSON files at that escaped location. The agent name is also interpolated directly into a JSON string. Names containing double quotes, backslashes, control characters, or newlines can produce malformed JSON or inject additional JSON properties. The same value is inserted into generated Markdown without validation. The `-f` checks reduce the ability to overwrite existing regular files, but they do not prevent directory creation or the placement of new files outside the expecte ...[truncated 1360 chars]
Remediation
View remediation
&2 exit 1 fi ``` 2. Explicitly reject path separators, `.` and `..` components, control characters, and leading hyphens. 3. Canonicalize the workspace and proposed destination, then verify that the destination remains under the canonical `workspace/agents/` directory. 4. Reject symbolic-link components or use directory-relative, no-follow filesystem operations where available. 5. Generate JSON through a JSON-aware utility or language library rather than direct heredoc interpolation. For example, use Python's `json.dump` with the agent name passed as data. 6. Validate the workspace path before creating files and avoid operating on unexpected symlinked workspace directories. 7. Add tests covering traversal strings, quotes, backslashes, newlines, Unicode control characters, duplicate names, and excessively long names. ]]>

T02 · Agent Memory Poisoning

Error
Location
references/self-improvement.md:20
Finding

Conversation-Derived Learnings Can Be Auto-Promoted Into Persistent Agent Instructions

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
Findings (20)

Tp4

High
Category
MCP Tool Poisoning
Confidence
93% confidence
Finding

The declared description promises a high-level, personalized council-builder that interviews the user, analyzes their workflow, and creates specialized AI personas with adaptive routing and coordination behavior. The supplied code chunk only initializes directories and template files for a workspace and named agents. It does create artifacts related to weekly learning metrics and architecture documentation, which partially aligns with the description, but these are static scaffolding files rather than functioning routing, learning, or coordination systems. The code’s primary purpose is project structure initialization, so the description materially overstates what this chunk actually does.

Content

No source excerpt is available for this finding.

Hidden Instructions

High
Category
Prompt Injection
Confidence
70% confidence
Finding

Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.

Content

Scanner excerpt · assets/SOUL-TEMPLATE.md (reported line 67)May include surrounding context.

md
---

<!-- Only include instructions that deviate from Claude's default behavior -->

## References
- `references/domain-guide.md` — deep domain knowledge (read on-demand)

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · references/config-patterns.md (reported line 37)May include surrounding context.

md
"language_priority": ["en", "ar"],
    "max_source_age_days": 7
  },
  "api_keys_ref": ["keychain:openclaw-x-api"],
  "custom_settings": {
    "min_sources_per_report": 3
  }

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · references/config-patterns.md (reported line 72)May include surrounding context.

md
"language_priority": ["en", "ar"],
    "max_source_age_days": 7
  },
  "api_keys_ref": ["keychain:openclaw-x-api"],
  "custom_settings": {
    "min_sources_per_report": 3
  }

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
70% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · references/gotchas-patterns.md (reported line 53)May include surrounding context.

markdown
## Force push on shared branches

**What goes wrong:** Claude suggests `git push --force` to fix diverged branches.

**The fix:** Always use `git push --force-with-lease` or rebase + normal push. Never force push main/develop.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill instructs the agent to scan memory/ files, workspace structure, and installed skills as part of optional history analysis without requiring explicit informed consent at the moment of access. That can expose sensitive project details, personal notes, or behavioral history beyond what the user expected when merely asking to build an agent council.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger phrase "remember this" causes persistence based on a broad natural-language pattern rather than an explicit consent or structured memory command. In a multi-agent council-building skill that emphasizes long-term memory and learning, this can lead to unintended storage of sensitive or irrelevant user data from ordinary conversation, increasing privacy and prompt-injection risk.

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 · assets/ROOT-AGENTS-TEMPLATE.md (reported line 38)May include surrounding context.

md
- No exfiltrating private data
- `trash` > `rm`
- No destructive commands without asking

## External vs Internal

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The routing table instructs authors to define trigger conditions as patterns matched against user input, but it provides no specificity, precedence, or exclusion requirements. In a system that creates specialized personas and routes tasks adaptively, ambiguous triggers can cause the wrong agent to activate, exposing user content to unnecessary contexts, causing unsafe tool use, or bypassing intended human review boundaries.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The documented first-run flow instructs agents to collect and persist user preferences across sessions, but it does not require informing the user that data will be stored or obtaining consent. In a multi-agent personalization skill, silent persistence can lead to privacy surprises, overcollection, and retention of sensitive workflow information that users may not expect to be written to disk.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger conditions include broad natural-language phrases such as general requests for writing, code help, news, or scheduling, which can match many unrelated user prompts and cause the wrong agent to activate. In a council-building skill, misrouting is security-relevant because it can expose user input, context, or downstream file paths to unnecessary agents and lead to unintended actions in a multi-agent workflow.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The logging rules instruct agents to persist user corrections, knowledge gaps, best practices, and feature requests in natural-language files. Because these categories can easily include sensitive user-provided details, preferences, workflow information, or confidential context, the design creates a broad data retention surface without minimization or redaction requirements.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The promotion rule says that if a user explicitly says 'remember this,' the information should be promoted immediately to more permanent files. That wording encourages durable storage based on a semantic trigger rather than a sensitivity check, so users may inadvertently cause long-term retention of secrets, personal data, or confidential instructions.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file directs agents to initialize and maintain persistent learning and metrics files, but it does not require explicit user notice or consent before writing to disk. In a skill that operates on user workflows and conversations, silent persistence can store user-derived content unexpectedly and create privacy, compliance, and trust issues.

Content

No source excerpt is available for this finding.

Behavior Manipulation

Medium
Category
Prompt Injection
Confidence
70% confidence
Finding

Subtle instructions detected that may alter agent decision-making or introduce hidden biases.

Content

Scanner excerpt · references/soul-philosophy.md (reported line 149)May include surrounding context.

md
- "Be helpful and accurate"

**Good (deviations from default):**
- "Always use our internal logger instead of console.log"
- "Always check @competitor's Twitter before writing market analysis"
- "Never use exclamation marks in any output"
- "Default to Najdi dialect, not MSA, for Arabic content"

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The example instruction 'Default to Najdi dialect, not MSA, for Arabic content' prescribes a specific language variety by default rather than based on user choice. The policy for this audit flags language or locale constraints unless they are user-selectable or clearly justified as region-specific.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
76% confidence
Finding

This natural-language/config example encodes a language ordering that could be interpreted as a default locale preference without explicit user opt-in or justification. Even though presented as an example, the document does not clarify that language choice should be user-selected.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The Content Agent example says "Never use exclamation marks" in Arabic content because "User bans them," but the example is written as a general gotcha pattern rather than clearly scoped to a specific opted-in user preference. This can be read as enforcing a language-output constraint for Arabic by default, which risks violating locale/language policy expectations.

Content

No source excerpt is available for this finding.

Ssd 3

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

The SOUL.md integration instructs every agent to log new learnings whenever the user corrects any output. While useful for quality improvement, this broadly captures user-supplied corrections and feedback, which may include sensitive or identifying content, expanding retention beyond what is necessary.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.