Back to skill

Security audit

clawhub

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed ClawHub registry installer, but it installs remote skill packages into an active local skills directory without enough validation or containment.

Review before installing. This skill is not inherently malicious, but it gives an agent a convenient way to install remote skills that persist across sessions. Use only with trusted ClawHub packages, avoid untrusted slugs or URLs, and prefer a version that validates slugs, verifies package integrity, stages downloads for review, and asks before overwriting installed skills.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (2)

T08 · Insecure Dependencies

Error
Location
clawhub-download.sh:72
Finding

Unverified Remote Skill Packages Are Installed into an Active Agent Skill Directory

Content
View full analysis
/dev/null; then echo -e "${RED}Error: Downloaded file is not a valid zip archive.${NC}" exit 1 fi # Extract skill package echo -e "${YELLOW}Extracting skill package...${NC}" unzip -o "$TEMP_DIR/skill.zip" -d "$TEMP_DIR/extracted" &> /dev/null # Check for SKILL.md if [ ! -f "$TEMP_DIR/extracted/SKILL.md" ]; then echo -e "${RED}Error: Downloaded package does not contain SKILL.md${NC}" exit 1 fi # Create skill directory skill_dir="$SKILLS_DIR/$slug" mkdir -p "$skill_dir" # Copy files to skill directory echo -e "${YELLOW}Installing skill to $skill_dir...${NC}" cp -r "$TEMP_DIR/extracted/"* "$skill_dir/" ``` ```bash echo -e "${GREEN}The skill is now available for use!${NC}" echo -e "Restart your agent to load the new skill, or it will be loaded on next session." ``` ### Technical Analysis The downloader retrieves a mutable package from an external registry and installs its contents under `~/.agents/skills/clawhub-skills`, an agent skill directory. The only package authenticity checks are that the response has HTTP status 200, is syntactically a ZIP archive, and contains a file named `SKILL.md`. There is no verification of: - A cryptographic package signature. - A trusted publisher identity. - An expected package checksum. - A pinned package version or immutable artifact identifier. - The saf ...[truncated 2008 chars]
Remediation
View remediation

T05 · Unauthorized Access and Privilege Escalation

Error
Location
clawhub-download.sh:33
Finding

Unsanitized Skill Slug Allows Installation Path Traversal

Content
View full analysis
Remediation
View remediation
&2 exit 1 fi ``` 2. Reject slashes, backslashes, `..`, percent-encoded separators, control characters, query delimiters, fragments, and empty values. 3. Parse ClawHub URLs using a proper URL parser or enforce the exact expected form. Ensure the extracted slug is one path segment and that no query or fragment is accepted as part of it. 4. URL-encode the validated slug when constructing the API request. 5. Canonicalize both the installation root and destination, then verify that the destination is a direct child of the installation root before creating or copying files. 6. Refuse installation if the destination already exists unless an explicit, controlled upgrade operation is requested. 7. Copy into a newly created staging directory beneath `SKILLS_DIR`, validate it, and atomically rename it to the final validated destination. 8. Add regression tests covering values such as `../target`, `owner/../../target`, absolute paths, repeated separators, encoded traversal strings, and malformed ClawHub URLs. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (8)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The documented behavior does not fully match the operational behavior: it installs content, uses a backend API on a different domain, and reportedly inspects local installed skills without clearly disclosing those actions. Behavior mismatches are dangerous because they undermine informed consent and can hide supply-chain, privacy, or persistence risks behind a seemingly simple registry-browsing skill.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
93% confidence
Finding

The skill advertises shell-based operations that download and install code but does not declare any tool scope or permissions boundaries. That makes the capability less transparent to the user and host agent, increasing the chance that network access and filesystem writes occur without adequate review or sandboxing.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill tells the agent to install downloaded content into the user's home directory but does not prominently warn about that persistent filesystem modification. Writing third-party packages into a long-lived user-controlled path creates supply-chain and persistence risk, especially if users believe they are only browsing or searching a registry.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · clawhub-download.sh (reported line 51)May include surrounding context.

sh
echo ""

# Check dependencies
if ! command -v curl &> /dev/null; then
    echo -e "${RED}Error: curl is required but not installed.${NC}"
    exit 1
fi

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script does more than browse or download: it automatically installs untrusted remote content into the agent's active skills directory. Because skills can later influence agent behavior or execute follow-on logic, this creates a supply-chain trust boundary violation and can persist malicious content locally without any validation step.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script writes downloaded files into the user's local skills directory without prompting, and uses recursive copy semantics that may overwrite existing skill content. This removes an important user-consent checkpoint and makes accidental or malicious replacement of local skill files much easier.

Content

No source excerpt is available for this finding.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · clawhub-search.sh (reported line 135)May include surrounding context.

sh
# Main
if ! command -v jq &> /dev/null; then
    echo "Error: jq is required but not installed."
    echo "Install it with: sudo apt-get install jq"
    exit 1
fi

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

When a keyword is provided, the script announces the search and then queries a remote service to retrieve matching skills. While the script's purpose is search, there is no explicit disclosure in comments or output that user-provided search terms are transmitted off-host to an external API endpoint.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.