Back to skill

Security audit

Opentask Skill

Security checks for vulnerabilities and agentic risk

Overview

The skill is a legitimate task-management client, but its heartbeat workflow can make the agent act on remote tasks without clear validation or user approval.

Install only if you trust the OpenTask service and can restrict it. Do not enable automatic HEARTBEAT execution unless tasks are limited to reviewed, allowed task types with explicit approval for consequential actions. Use a narrowly scoped API key, require HTTPS for non-local hosts, and avoid putting secrets or sensitive personal data in task names, descriptions, parameters, or results.

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
SKILL.md:128
Finding

Untrusted Remote Tasks Can Redirect Agent Behavior During Heartbeat Processing

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • 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
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (14)

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

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

Content

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

配置 OPENTASK_BOT_NAME 环境变量:

bash
# .env 文件
OPENTASK_BOT_NAME=anna

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

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

bash
# 使用 Runtime agent 值
curl -H "X-Bot-Key: $OPENTASK_API_KEY" \
  "$OPENTASK_HOST/api/tasks/pending?assigned_to={agent}"

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

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

md
BOT_NAME="main"

# 获取待执行任务
TASKS=$(curl -s -H "X-Bot-Key: $OPENTASK_API_KEY" \
  "$OPENTASK_HOST/api/tasks/pending?assigned_to=$BOT_NAME")

# 解析任务数量

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

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

md
echo "有 $COUNT 条待执行任务"
  # 开始执行第一条任务
  TASK_ID=$(echo "$TASKS" | python3 -c "import sys,json; print(json.load(sys.stdin)[0]['id'])")
  curl -X PUT -H "X-Bot-Key: $OPENTASK_API_KEY" "$OPENTASK_HOST/api/tasks/$TASK_ID/start"
else
  echo "HEARTBEAT_OK"
fi

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

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

md
echo "有 $COUNT 条待执行任务"
  # 开始执行第一条任务
  TASK_ID=$(echo "$TASKS" | python3 -c "import sys,json; print(json.load(sys.stdin)[0]['id'])")
  curl -X PUT -H "X-Bot-Key: $OPENTASK_API_KEY" "$OPENTASK_HOST/api/tasks/$TASK_ID/start"
else
  echo "HEARTBEAT_OK"
fi

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% 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 · SKILL.md (reported line 95)May include surrounding context.

bash
# 使用 Runtime agent 值
curl -H "X-Bot-Key: $OPENTASK_API_KEY" \
  "$OPENTASK_HOST/api/tasks/pending?assigned_to={agent}"

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill documents APIs that create tasks and mutate shared task state (start, complete, fail, retry, cancel) but does not instruct the agent to obtain explicit user confirmation before performing those actions. In a shared task system, this can cause unintended task creation or state transitions that affect other operators and automated workers, especially if invoked from natural-language prompts without clear guardrails.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The HEARTBEAT section encourages automatic polling and execution of pending tasks, including starting tasks and then 'executing task logic,' without a warning that this enables unattended actions. If task contents are influenced by external users or other systems, the agent may automatically perform sensitive actions without review, amplifying the risk of prompt injection or unsafe automation.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% 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 · SKILL.md (reported line 217)May include surrounding context.

md
echo "有 $COUNT 条待执行任务"
  # 开始执行第一条任务
  TASK_ID=$(echo "$TASKS" | python3 -c "import sys,json; print(json.load(sys.stdin)[0]['id'])")
  curl -X PUT -H "X-Bot-Key: $OPENTASK_API_KEY" "$OPENTASK_HOST/api/tasks/$TASK_ID/start"
else
  echo "HEARTBEAT_OK"
fi

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% 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 · SKILL.md (reported line 238)May include surrounding context.

md
# 2. 目标实例开始执行(在其 heartbeat 时)
# 3. 完成任务
curl -X PUT -H "X-Bot-Key: $OPENTASK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"result":"问候已发送"}' \
  "$OPENTASK_HOST/api/tasks/$TASK_ID/complete"

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The documentation instructs users to supply and transmit a live API key via the X-Bot-Key header, but it does not warn about treating the key as a secret, avoiding logs/history exposure, or using secure transport. In an agent skill context, this increases the chance that operators paste secrets into prompts, shells, screenshots, or insecure environments, enabling unauthorized access to the task management API.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% 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 · references/api.md (reported line 30)May include surrounding context.

所有 API 请求需要携带 X-Bot-Key 请求头:

bash
curl -H "X-Bot-Key: $OPENTASK_API_KEY" "$OPENTASK_HOST/api/tasks"

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The reference documents multiple state-changing endpoints such as create, start, complete, fail, retry, and cancel without clearly warning that these operations mutate remote task state and may trigger real workflow effects. In an agent-integrated environment, this can cause accidental or unauthorized operational changes if a user or model invokes examples as if they were read-only.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
94% confidence
Finding

The file presents operational instructions entirely in Chinese and does not indicate that the skill or reference is region-specific or provide an alternative language option. Under the stated policy, forcing a specific language without opt-in or justification is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.