Back to skill

Security audit

Task Assessor

Security checks for vulnerabilities and agentic risk

Overview

The skill is not clearly malicious, but it expands from task assessment into global task interception, persistent user-intent storage, and execution gating that users should review carefully.

Install only if you want a Chinese-language task-assessment skill that may also act as a broad clarification and confirmation gate. Review the local cache behavior first, especially storage of original prompts and learned defaults under ~/.openclaw, and avoid enabling its deletion whitelist or global interception semantics without tighter scoping and reset controls.

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
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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 (4)

T01 · Skill Instruction Hijacking

Error
Location
SKILL.md:3
Finding

Global Instruction and Execution-Flow Hijacking

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 3, 18, and 212-228
Vulnerability Type: Global interception and redirection of unrelated user tasks
Risk Level: High

Vulnerable Instruction Excerpts

The following translated excerpts preserve the meaning of the source instructions:

text
Automatically detect task difficulty. Tasks at L3 or above must be reported
and confirmed before execution.

All user instructions must pass through this module before entering the
execution engine.

L3, L4, or L5:
- Output an assessment report first.
- Then request confirmation.

Technical Analysis

The Skill metadata describes activation for task assessment, complexity analysis, cost estimation, duration estimation, skill requirements, and task planning. However, the body instructs the Agent to intercept all user instructions, including requests unrelated to task assessment.

The mandatory L3-L5 confirmation gate further changes the Agent's normal execution policy. Once loaded, the Skill can classify a request as ambiguous or sufficiently complex and replace normal execution with a questionnaire or confirmation request. This is a session-wide behavioral override rather than an advisory assessment function.

The problematic behavior is caused by the combination of:

  1. Universal interception before the execution engine.
  2. Skill-controlled ambiguity classification.
  3. Mandatory blocking of L3-L5 requests.
  4. Replacement of the requested workflow with a Skill-generated assessment or questionnaire.

Attack Path

  1. The Skill is loaded for an assessment-related request.
  2. The user subsequently submits any request, including one outside the declared assessment scope.
  3. The Skill applies its universal interception instruction.
  4. It classifies the request as ambiguous or L3-L5.
  5. The original operation is withheld.
  6. A Skill-controlled questionnaire or confirmation flow replaces ...[truncated 716 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove the instruction requiring every user request to pass through this module.
  2. Restrict activation to explicit task-assessment requests or a user-enabled assessment mode.
  3. Make complexity reports advisory rather than mandatory execution gates.
  4. Apply confirmation requirements only to concrete high-risk side effects, not merely to task complexity.
  5. Ensure that unrelated requests bypass the Skill after the assessment interaction ends.
  6. Document precise activation and deactivation boundaries.
  7. Add tests verifying that non-assessment requests are not intercepted.

T02 · Agent Memory Poisoning

Warning
Location
scripts/intent-clarifier-cache.js:9
Finding

Plaintext Cross-Session Storage of User Requests and Behavioral Preferences

Content
View full analysis

Vulnerability Details

File Location: scripts/intent-clarifier-cache.js, lines 9-12, 33-42, and 103-132
Vulnerability Type: Persistent plaintext state, insufficient session isolation, and memory poisoning risk
Risk Level: Medium

Vulnerable Code

js
const CACHE_DIR = path.join(
  process.env.USERPROFILE || process.env.HOME,
  '.openclaw',
  'data',
  'intent-clarifier'
);
const CACHE_FILE = path.join(CACHE_DIR, 'cache.json');
const PREFS_FILE = path.join(CACHE_DIR, 'prefs.json');
const TRANSLATIONS_FILE = path.join(CACHE_DIR, 'translations.json');

saveClarification(sessionId, originalIntent, vulnerabilities) {
  const cache = {
    sessionId,
    originalIntent,
    vulnerabilities,
    createdAt: Date.now(),
    expiresAt: Date.now() + CACHE_TTL
  };
  fs.writeFileSync(CACHE_FILE, JSON.stringify(cache, null, 2));
  return cache;
}

updatePrefs(userId, taskType, field, value) {
  let prefs = {};
  if (fs.existsSync(PREFS_FILE)) {
    try {
      prefs = JSON.parse(fs.readFileSync(PREFS_FILE, 'utf8'));
    } catch (e) {}
  }

  if (!prefs[userId]) prefs[userId] = {};
  if (!prefs[userId][taskType]) prefs[userId][taskType] = {};

  if (!prefs[userId][taskType][field]) {
    prefs[userId][taskType][field] = { value, count: 1 };
  } else if (prefs[userId][taskType][field].value === value) {
    prefs[userId][taskType][field].count += 1;
  } else {
    prefs[userId][taskType][field] = { value, count: 1 };
  }

  fs.writeFileSync(PREFS_FILE, JSON.stringify(prefs, null, 2));
  return prefs[userId][taskType][field];
}

Technical Analysis

The implementation stores raw user intent, session identifiers, inferred vulnerabilities, and learned preference values in predictable JSON files beneath the user's home directory.

The writes do not explicitly set restrictive file permissions. Actual access therefore depends on the parent directory permissio ...[truncated 2611 chars]

Remediation
View remediation

Remediation Suggestions

  1. Avoid storing raw user requests; retain only the minimum structured fields required for clarification.
  2. Isolate cache records by authenticated user ID and cryptographically unpredictable session ID.
  3. Require getClarification() to receive and verify the expected user and session identifiers.
  4. Create the storage directory with mode 0700 and files with mode 0600.
  5. Use atomic writes through a private temporary file followed by a rename.
  6. Encrypt sensitive persisted state using platform-backed key storage where available.
  7. Add expiration to learned preferences and require explicit user opt-in before applying automatic defaults.
  8. Never use a shared "default" identity where multiple users or sessions may access the runtime.
  9. Validate stored JSON against a strict schema before using it to influence future tasks.
  10. Provide users with clear controls to inspect, reset, and disable persistent preferences.

T09 · Insecure Skill Coding Practices

Warning
Location
references/risk-whitelist.md:81
Finding

Overbroad Whitelist for Destructive Operations in Shared Temporary Directories

Content
View full analysis

Vulnerability Details

File Location: references/risk-whitelist.md, lines 81-91
Vulnerability Type: Unsafe destructive-operation authorization policy
Risk Level: Medium

Vulnerable Configuration

json
{
  "whitelist": {
    "paths": [
      "C:\\Users\\Admin\\.openclaw\\workspace\\temp\\*",
      "C:\\Windows\\Temp\\*",
      "/tmp/*",
      "/var/tmp/*"
    ]
  }
}

The accompanying policy states that deletion operations in these temporary directories may proceed without the normal high-risk confirmation.

Technical Analysis

The policy treats directory location as sufficient evidence that deletion is low risk. However, /tmp, /var/tmp, and system-wide Windows temporary directories are shared resources and may contain:

  • Files belonging to unrelated users or applications.
  • Unix-domain sockets and other IPC endpoints.
  • Lock files and service coordination data.
  • Temporary databases or recovery files.
  • Symlinks or junctions pointing outside the expected directory.
  • Security-sensitive runtime artifacts.

A wildcard covering every descendant of a shared temporary directory is substantially broader than a whitelist restricted to files created and owned by this Skill. The policy excerpt also does not require canonical-path validation, ownership checks, symlink rejection, or enumeration of affected files.

Attack Path

  1. An attacker creates or identifies a valuable file, lock, socket, or symlink under a whitelisted temporary directory.
  2. The user or Agent receives a request to clean that directory or delete a matching path.
  3. The risk policy matches the broad /tmp/*, /var/tmp/*, or equivalent Windows wildcard.
  4. The normal destructive-operation confirmation is bypassed.
  5. The deletion removes unrelated resources or follows an unsafe path-resolution condition.
  6. Another application may lose data, fail, or become unavailable.

Impact Assessment

...[truncated 551 chars]

Remediation
View remediation

Remediation Suggestions

  1. Remove wildcard exemptions for system-wide temporary directories.
  2. Restrict automatic deletion to a dedicated, Skill-owned directory created with restrictive permissions.
  3. Resolve and validate canonical paths before deletion.
  4. Reject symlinks, junctions, mount-point traversal, and paths escaping the approved root.
  5. Verify that each target was created by the Skill and is owned by the expected account.
  6. Enumerate targets and present their count, total size, and canonical paths before recursive or multi-file deletion.
  7. Require explicit confirmation for recursive deletion even inside the Skill-owned temporary directory.
  8. Apply age and filename constraints only as supplemental checks, not as the sole authorization mechanism.
  9. Log deletion decisions without recording sensitive file contents.

T09 · Insecure Skill Coding Practices

Note
Location
scripts/intent-clarifier-cache.js:181
Finding

Broken Translation Persistence Routine Caused by Undeclared and Inconsistent Identifiers

Content
View full analysis

Vulnerability Details

File Location: scripts/intent-clarifier-cache.js, lines 181-200
Vulnerability Type: Runtime exception and inconsistent duplicate-detection logic
Risk Level: Low

Vulnerable Code

js
addTranslation(original, 补充, interpretation) {
  let translations = this.getTranslations();
  const key = original.toLowerCase().trim();

  if (!translations[key]) translations[key] = [];

  const exists = translations[key].some(t =>
    t.supplement === supplement && t.interpolation === interpretation
  );

  if (!exists) {
    translations[key].push({ supplement, interpretation, count: 1 });
  } else {
    translations[key].find(t =>
      t.supplement === supplement && t.interpolation === interpretation
    ).count += 1;
  }

  fs.writeFileSync(
    TRANSLATIONS_FILE,
    JSON.stringify(translations, null, 2)
  );
}

Technical Analysis

The second function parameter is named 补充, while the function body reads the undeclared identifier supplement. In JavaScript, evaluating that identifier raises a ReferenceError unless an unrelated global variable with that name exists.

The duplicate-detection condition also reads t.interpolation, but newly stored records use the property interpretation. Even if the undeclared-variable defect were corrected independently, the property mismatch would prevent reliable duplicate matching and cause duplicate records or incorrect counts.

The routine has no local exception handling, so the runtime error propagates to its caller and prevents translation persistence.

Attack Path

  1. A code path invokes addTranslation() with otherwise valid arguments.
  2. Execution reaches the duplicate-detection callback.
  3. JavaScript evaluates the undeclared supplement identifier.
  4. A ReferenceError is thrown.
  5. The translation record is not written.
  6. If the caller does not catch the exception, the surrounding clarificati ...[truncated 643 chars]
Remediation
View remediation

Remediation Suggestions

  1. Rename the second parameter to supplement and use that identifier consistently.
  2. Replace every t.interpolation reference with t.interpretation.
  3. Validate that original, supplement, and interpretation are strings before calling string methods or persisting data.
  4. Add tests covering insertion, duplicate detection, count incrementing, malformed input, and persistence failures.
  5. Handle filesystem and parsing errors explicitly rather than silently ignoring or propagating unexpected failures.
  6. Consider schema validation for every translation entry loaded from disk.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (28)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared purpose is task assessment, but the document also defines pre-execution interception, persistence of user instructions/preferences, skip-reinterception logic, and operational control over later execution. This mismatch can let a broadly triggered 'assessment' skill become a hidden orchestration and policy-affecting component, increasing the chance of unauthorized data retention or unsafe control flow.

Content

No source excerpt is available for this finding.

Vague Triggers

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The statement that all user instructions are checked before execution makes the trigger scope effectively global and unclear. Overbroad activation in an agent skill is dangerous because it can unexpectedly capture unrelated tasks, collect data from them, and influence routing or execution without user awareness.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The file’s behavior materially differs from the declared skill purpose: instead of assessing task difficulty/cost, it defines intent-clarification and ambiguity detection logic. This kind of scope drift is dangerous because it can cause the agent to invoke an unintended capability path, bypass user expectations, and weaken safety review by hiding real behavior behind misleading metadata.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The manifest requires automatic difficulty detection and mandatory report-and-confirm behavior for L3+ tasks, but the file only defines clarification thresholds and skip rules. Missing this control is dangerous because higher-risk tasks may proceed without the required friction, review, or explicit user confirmation, undermining a stated safety gate.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The parser documentation includes domain logic for stock analysis and file operations that is unrelated to a task-assessment skill. In an agent setting, this kind of capability drift can cause the skill to misinterpret user input, collect unintended parameters, or route toward actions outside its declared scope, increasing the chance of unsafe or unauthorized behavior.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The state machine explicitly says that once required fields are complete, the system should '补全参数,执行' ('fill parameters and execute'), which exceeds the declared purpose of this skill. For a task-assessment skill whose metadata requires reporting and confirmation for higher-risk tasks, auto-execution creates a scope escalation path that could bypass confirmation and trigger unintended downstream actions.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

This file implements persistent intent-clarification, preference, and translation storage that is materially outside the declared purpose of a task-assessment skill. In a skill ecosystem, capability mismatch is dangerous because it enables undisclosed collection and retention of user data, expands attack surface, and makes review and consent difficult.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The file header explicitly identifies the component as an intent-clarifier cache manager, which contradicts the advertised task-assessor skill purpose. Such deception or mislabeling undermines trust boundaries: reviewers and users may approve a skill expecting low-risk task estimation while it actually stores conversational interpretation data.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
87% confidence
Finding

The skill references local state files under ~/.openclaw and thus implies filesystem/environment-capable behavior, but it declares no explicit tool scope or permissions boundary. In an agent system, undeclared capability expansion is dangerous because reviewers and policy layers may assume the skill is assessment-only while it can read or write local state and influence future executions.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

Several trigger phrases such as task planning, difficulty analysis, or needed skills are broad enough to match many ordinary requests. In context, this is more dangerous because the skill also performs interception and persistence, so accidental activation can lead to unnecessary data collection and control-flow changes.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This section states that all user instructions pass through the module before execution, effectively inserting a global gatekeeper rather than a narrow assessment helper. A skill with ambiguous global interception can alter routing and execution decisions outside its advertised role, which is risky in multi-skill agent environments.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The workflow includes direct execution, waiting for supplemental answers, parameter completion, and re-submission that skips re-interception. That creates control-flow authority and a potential bypass path where later checks may be skipped based on locally persisted state, exceeding an assessment skill's safe scope.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill stores original user instructions and inferred clarification data in local cache files, but the description does not provide a clear user-facing notice about retention. Hidden storage of raw intents is risky because prompts often contain sensitive business, personal, or operational details that persist beyond the immediate task.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill learns defaults across sessions after repeated choices and persists them without explicit opt-in. Cross-session behavioral profiling can surprise users, leak preferences into later tasks, and create incorrect or privacy-invasive assumptions about future intent.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

Per-user preference storage and history-based inference can cause user-provided choices to surface in later responses or sessions, effectively leaking prior data into new contexts. This is especially risky in shared or multi-tenant environments, or when the stored preferences reveal finance, work, or communication habits.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

Manifest只要求对L3及以上任务在执行前先报告并确认,而L109-L118进一步定义了针对删除文件、批量发送、修改系统配置等高风险操作的专门二次确认机制和风险白名单。这是面向操作安全的执行控制策略,不是单纯的任务难度/成本评估输出。该扩展能力与声明的技能核心目的不完全匹配。

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

This markdown template is entirely written in Chinese and presents the output format as the standard report format, with no indication that another language may be used. That creates a natural-language locale constraint that could violate language policy when users have not explicitly opted into Chinese.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The prompt template is written entirely in Chinese and prescribes Chinese field descriptions and question text, which can force a specific language/locale on users. The file does not mention that this language constraint is optional, user-selected, or limited to a justified region-specific deployment.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The document includes broad operational examples for stock analysis, file management, messaging, and data analysis that exceed a narrow 'task assessor' role. In context, this expands the effective scope of the skill and can lead to overbroad activation or downstream handling of sensitive actions outside the reviewed permission boundary.

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 file contains user-facing instructions, examples, and command syntax only in Chinese. Under the language/locale policy rule, forcing a specific language without user opt-in or an explicit justified regional scope is a natural-language policy violation.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill metadata states that tasks at L3 and above must be reported and confirmed before execution, but this document classifies P3 as low risk and allows direct execution without confirmation. That mismatch can cause the agent to skip required confirmations for actions the broader skill contract says must be surfaced first, creating unsafe execution behavior through inconsistent policy interpretation.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The message-risk logic comments say external channels or bulk recipients are high risk, but the function returns P0 while other parts of the document use different labels and confirmation semantics. In a task-assessment skill, inconsistent classification of outbound messaging can cause under- or mis-handling of mass/external communications, potentially enabling unintended spam, data leakage, or unsafe automation.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The preference and translation databases are unrelated to task difficulty/cost assessment and create persistent profiling capability without clear necessity. Even if not overtly malicious, unnecessary retention of user-specific behavior and language inputs increases privacy risk and can be abused by other local processes or future code changes.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The code writes preferences, translations, and cache data to persistent files under the user's home directory with no visible disclosure, consent, or access control considerations. Persistent local storage of natural-language inputs and inferred preferences can expose sensitive information to other software on the same system and violates least surprise.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

Persisting session cache and learned preferences for a task-assessment skill is not clearly necessary and increases data retention risk. Even if the stored data is not highly sensitive by design, original intents and inferred preferences can reveal behavioral patterns and leak across future sessions.

Content

No source excerpt is available for this finding.