Back to skill

Security audit

feishu-process-feedback

Security checks for vulnerabilities and agentic risk

Overview

This Feishu task bot is mostly a coherent scaffold, but its task text can be passed into shell commands and retained in logs, which makes it unsafe to install without review.

Do not install this version for a real Feishu workspace until the shell-command construction is replaced with shell-free argument passing, raw task logging is removed or redacted, triggers are restricted to explicit authorized invocations, and the documentation is corrected to state which features are implemented versus placeholders.

Vulnerability Patterns
  • 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
  • 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 (2)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/process_task.js:79
Finding

Shell Command Injection Through Attacker-Controlled Feishu Task Content

Content
View full analysis
60 ? '...' : ''}` ); ``` ```javascript const preview = subtask.replace(/^[\d\-\*•]+[\.\)]\s*/, '').substring(0, 50); ``` ```javascript await sendFeedback(`✅ Completed ${progress}% - ${preview}...`); ``` ### Technical Analysis The task processor receives Feishu task text through `process.argv[2]`. Portions of that text are subsequently included in progress messages and passed to `sendFeedback()`. `sendFeedback()` constructs a command string and executes it with `execAsync()`. Node.js `exec()` invokes a system shell. The implemented escaping only handles backslashes, double quotes, newlines, and carriage returns. It does not safely neutralize shell expansion features that remain active inside double-quoted shell strings, including command substitution using `$(...)` or backticks. Consequently, task text is interpreted partly as shell syntax rather than exclusively as the value of the `--message` argument. This is a direct command-i ...[truncated 1878 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/process_task.js:58
Finding

Sensitive Task Content Is Persisted in Plaintext Logs

Content
View full analysis
Remediation
View remediation
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
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (29)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The description largely matches the intended architecture of the code: a background service with retry logic, persistence, process management, concurrency control, and feedback messaging. However, several central declared capabilities are only partially implemented or merely scaffolded. Most importantly, the listener does not actually fetch Feishu messages—getLatestMessage() is explicitly a TODO and always returns null—so the advertised core behavior of monitoring and automatically handling Feishu task messages does not currently occur. In addition, the claimed real-time progress reporting (including percentage and completion notifications) is not present in this file; only initial acknowledgment, queue warning, timeout, and shutdown messages are sent. The task parsing is also far simpler than the declared 'smart parsing' and 'task type recognition.' Because these gaps affect the primary advertised functionality rather than minor implementation details, this is a material description-behavior mismatch.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
92% confidence
Finding

描述强调的是一个完整的飞书自动化后台技能,核心能力应包括监听消息、调度任务进程、并发控制和状态持久化。实际代码仅覆盖其中一部分:对已传入的任务文本做基础解析,按顺序循环处理,并发送飞书反馈消息与记录日志。该脚本更像“单个任务子处理器”,而不是描述中的完整后台监听与调度技能。虽然它确实包含进度反馈、基础任务分类、错误处理和重试,但缺失了声明中的关键主能力,且实际执行逻辑仍是模拟占位,因此描述与代码行为存在实质不匹配。

Content

No source excerpt is available for this finding.

Vague Triggers

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The trigger keywords are extremely broad and overlap with normal conversation, making accidental task activation likely. In a continuously running background listener that may launch processing automatically, false triggers can cause unintended actions, message leakage, queue flooding, or abuse by anyone who can send crafted chat text.

Content

No source excerpt is available for this finding.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node scripts/listener.js

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node scripts/listener.js

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node scripts/listener.js

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node scripts/listener.js

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node scripts/listener.js

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node scripts/listener.js

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
编辑 `scripts/process_task.js` 中的 `executeSubtask()` 函数:

Intent-Code Divergence

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

文件头部与类注释宣称该脚本会在后台监听飞书消息并创建处理进程,但实际 getLatestMessage() 明确写有 TODO,且当前实现仅记录“检查新消息”后直接返回 null。这不是单纯的实现细节缺失,而是文档所承诺的核心能力与代码当前行为相矛盾,导致技能实际上不会监听或处理任何飞书消息。

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The README promotes continuous background listening, message parsing, state persistence, and progress feedback, but does not clearly warn users that the skill monitors messages and may store task content in logs or state files. In a messaging environment, this creates privacy and compliance risk because users may not realize their conversations are being watched, retained, and acted upon automatically.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The example trigger is a normal-language request ('帮我处理这个任务…') that closely overlaps with routine chat and work messages. In a skill designed to continuously listen to Feishu messages and automatically spawn processing jobs, this can cause accidental activation on benign conversations, leading to unintended task execution, data processing, or outbound actions such as report generation or email sending.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill describes behavior that requires network access and likely environment-based secrets, but it does not explicitly declare a tool/permission scope. That creates hidden capability risk: operators may install a background listener without clear visibility that it will poll external APIs and use credentials, weakening review and consent boundaries.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

文件中的名称、描述、示例反馈文本和使用说明均固定为中文,没有说明这是特定区域/组织限定技能,也没有提供用户语言选择。若组织要求避免无选择地强制单一语言,这构成语言/locale 策略风险。

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The description under-communicates that the skill continuously monitors messages and automatically sends status updates over external channels. Insufficient disclosure is dangerous because users or administrators may deploy it without understanding that it is effectively a persistent bot processing communication data in the background.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
86% confidence
Finding

The extension guidance encourages implementers to add arbitrary task-processing logic, expanding the skill from message feedback into general-purpose execution. In a background, message-driven skill, that broadens the attack surface significantly because incoming chat content could become a trigger for higher-risk actions not constrained by the stated purpose.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

User-visible text and instructional comments throughout the file are written exclusively in Chinese, including status output and operational messages. There is no indication that the skill is region-specific or that users can opt into another language, which can violate language/locale policy requirements.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

User-controlled message content is interpolated into a shell command and executed through exec, with only double quotes and newlines escaped. Shell metacharacters such as backticks or command substitution syntax may still be interpreted by the shell, creating a command-injection path when feedback messages contain attacker-controlled text.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Manifest描述该技能会识别任务类型、智能解析并在独立进程中自动处理任务,还支持错误重试、并发控制和状态持久化。这里的核心执行函数仅sleep后直接返回成功,注释还明确写明“应集成具体业务逻辑”,说明实际行为主要是发送反馈与伪造完成状态,而非真正处理任务。

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The script sends task-derived content to an external messaging command and persists operational details to a local log without any minimization or consent controls. In a workflow processor, task text can easily contain sensitive business data, credentials, or personal information, so routine forwarding and persistence creates a real confidentiality risk.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The code logs taskPreview and the full CLI argument string (argv), both of which may include sensitive task text or identifiers supplied by users. Because these values are written to .tasks.log and also surfaced in status flows, anyone with log access or downstream message visibility may learn confidential contents that were never meant to be retained or shared.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The script repeatedly includes subtask previews and raw error text in outbound progress messages. In this skill context, progress updates are automatic and frequent, so sensitive instructions, names, internal project details, or error-derived secrets can be broadcast through routine operational messaging without review.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

This markdown file contains a destructive operation (rm -f .listener.log .tasks.log) that deletes local files, but the surrounding instructions do not explicitly warn the user that files will be removed. Under the markdown criteria for SQP-2, skills should disclose behaviors that can affect user data or system state.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

This markdown file contains user-facing instructions exclusively in Chinese, and there is no note that the language is optional or tailored to a specific audience. Under the policy rule, forcing a specific language without user opt-in can be a natural-language policy violation.

Content

No source excerpt is available for this finding.