Back to skill

Security audit

Agent Supervision

Security checks for vulnerabilities and agentic risk

Overview

This skill gives an agent a disclosed, narrow workflow for supervising another agent session, with no hidden code or deceptive behavior found.

Before using this skill, confirm the target sessionKey, check frequency or ETA rules, what counts as progress, escalation threshold, and when the cron should stop. Treat session history as potentially sensitive, and only supervise sessions you are authorized to access. If following the publishing notes, verify the official clawhub package source and avoid running global npm installs with elevated privileges.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T08 · Insecure Dependencies

Warning
Location
references/clawhub-publish.md:20
Finding

Unpinned Global npm Package Installation

Content
View full analysis

Vulnerability Details

File Location: references/clawhub-publish.md, line 20
Vulnerability Type: T08: Insecure Dependencies
Risk Level: Medium

Vulnerable Code:

bash
npm i -g clawhub

Technical Analysis

The publishing instructions install the latest available version of the clawhub npm package globally without pinning a reviewed version or verifying package integrity. Because npm packages can execute lifecycle scripts during installation, following this command may execute code supplied by the package with the invoking user's permissions.

The unpinned package reference is mutable: the code installed by this command can change after the skill has been audited. A compromised maintainer account, malicious package release, or supply-chain takeover could therefore turn this documented installation step into arbitrary local code execution. Global installation also increases the potential impact by placing the CLI in a system- or user-wide executable location.

Attack Path

  1. An attacker compromises the npm package, its publisher account, or a future release distributed under the referenced package name.
  2. The attacker publishes a malicious latest version, potentially including an npm lifecycle script.
  3. A user follows the documented npm i -g clawhub instruction.
  4. npm retrieves the mutable latest release and may execute its installation scripts.
  5. The malicious package runs with the user's privileges and can access files, environment variables, authentication material, and other resources available to that account.
  6. The globally installed CLI may remain available and execute attacker-controlled behavior during later publishing or authentication operations.

Impact Assessment

Successful exploitation could provide arbitrary code execution with the privileges of the user running npm. The accessible scope may include the user's files, environment variables, OpenClaw configuration ...[truncated 467 chars]

Remediation
View remediation

Remediation Suggestions

  • Pin the package to an exact, reviewed version instead of installing the mutable latest release:
    bash
    npm install --global clawhub@<reviewed-exact-version>
    
  • Verify the package name, publisher, provenance, and integrity against the official ClawHub distribution documentation before installation.
  • Prefer a project-local dependency governed by a committed lockfile over a global installation when the workflow supports it.
  • Use npm provenance and integrity controls, and review package contents and lifecycle scripts before approving version updates.
  • Consider --ignore-scripts when the official package does not require lifecycle scripts:
    bash
    npm install --global --ignore-scripts clawhub@<reviewed-exact-version>
    
  • Avoid running npm with sudo, root, or administrator privileges.
  • Document the expected official registry and trusted package source to reduce dependency-confusion and registry-substitution risks.
  • Treat package upgrades as security-relevant changes requiring review rather than automatically consuming the newest release.
Vulnerability Patterns
  • Memory PoisoningPersistent Context Injection, Context Window Stuffing, Memory Manipulation
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (1)

Context Window Stuffing

Medium
Category
Memory Poisoning
Confidence
85% confidence
Finding

Skill attempts to fill the context window with filler content, displacing legitimate instructions and safety constraints. This can degrade agent performance or bypass safety boundaries.

Content

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

md
- job timeout: at least 120s, preferably 180s if the prompt contains ETA logic
- payload timeoutSeconds: 60-120s depending on complexity
- do not overstuff the prompt with policy prose

## Example user requests