Back to skill

Security audit

微信公众号文章保存

Security checks for vulnerabilities and agentic risk

Overview

This skill has a coherent article-saving purpose, but it asks agents to run unpinned shell commands and can write or delete Feishu records, creating review-worthy supply-chain and command-safety risks.

Review before installing. Use only with trusted article URLs and least-privilege Feishu credentials, avoid enabling delete access unless needed, and replace the `npx -y bun` and `lark-cli` shell examples with pinned, verified executables and safe argument handling. Be aware that article links or content may be sent to Jina Reader, Feishu, browser tooling, and a model provider.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (2)

T08 · Insecure Dependencies

Error
Location
SKILL.md:45
Finding

Unpinned Dependency Download and Execution Through npx

Content
View full analysis
-o /tmp/wechat-article.md --timeout 60000 ``` ### Technical Analysis The workflow directs the agent to invoke `bun` through `npx -y` without specifying an exact package version or verifying package integrity. If the package is unavailable locally, `npx` can automatically download it from the configured npm registry and immediately execute it. The `-y` option suppresses the normal installation confirmation. Consequently, the code executed during a skill run is not fully represented by the audited artifact and can change after review. Security depends on the npm registry, package ownership, local npm configuration, and whichever package version resolves at execution time. A compromised package release, registry account, package source, or dependency-resolution configuration could result in arbitrary code executing with the same operating-system permissions and environment access as the agent. ### Attack Path 1. A user supplies a qualifying WeChat article URL and triggers the documented workflow. 2. The agent executes the documented `npx -y bun ...` command. 3. `npx` resolves an unpinned version of the `bun` package through the configured registry. 4. If it is not cached locally, the package is downloaded without interactive approval. 5. Package-controlled code executes under the agent's account. 6. A malicious package version could access files, environment variables, credentials, network resources, or tools available to that account. Exploitation requires compromise or manipulation of the resolved package, registry, or dependency-resolution environment. ### Impact Assessment Successful exploitation provides arbitrary code execution with the privileges of the process running the skill. The affected scope may include: - Reading or mo ...[truncated 431 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:45
Finding

Shell Command Injection Through Unquoted Dynamic Values

Content
View full analysis
-o /tmp/wechat-article.md --timeout 60000 ``` Record-deletion command at `SKILL.md:176-180`: ```bash lark-cli base +record-delete \ --base-token {{FEISHU_APP_TOKEN}} \ --table-id {{FEISHU_TABLE_ID}} \ --record-id \ --yes ``` ### Technical Analysis The documented shell commands interpolate dynamic values without shell-safe quoting or strict validation. These values include: - A configurable local script path. - A user-provided article URL. - A Feishu application token and table ID. - A record ID obtained from an external API response or lookup operation. If an implementation constructs these commands as shell strings, whitespace, command substitutions, redirection operators, separators, or other shell metacharacters in an interpolated value can alter the command's structure. Merely validating that a URL starts with the expected prefix is insufficient if the original string is later inserted into a shell command without safe argument handling. The deletion command also places the Feishu application token directly in the process command line. Depending on operating-system configuration, command-line arguments can be exposed through process inspection, diagnostic output, shell history, or logging. The risk applies when these documentation templates are executed through a shell with direct textual substitution. An implementation that uses a process API with a separate argument array and validates every value would not be vulnerable to shell interpretation. ### Attack Path #### Article-processing path 1. An attacker supplies an article URL containing shell-significant characters while preserving any minimally required URL prefix. 2. The workflo ...[truncated 1769 chars]
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (5)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The workflow sends article URLs and potentially full article contents to external services such as Jina Reader, Feishu, and a model used for sprout-note generation, but the description does not clearly warn users about this data transfer. This can cause unintended disclosure of copyrighted, sensitive, private, or regulated content, especially because users may assume the operation is local file saving only.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
87% confidence
Finding

The skill executes an unpinned package/tool invocation via npx -y bun, which can fetch and run whatever version is current at execution time. In a workflow that processes untrusted URLs and has local file write access, this creates a supply-chain and arbitrary-code-execution risk if the resolved package or dependency chain is compromised or changes unexpectedly.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill's primary purpose is article capture and persistence, but it also includes destructive record-deletion capability against Feishu. Adding deletion broadens privileges beyond the stated save workflow and increases the chance of accidental or abused data loss, especially if users or agents invoke the skill under ambiguous prompts.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
86% confidence
Finding

The manifest says the workflow triggers when the user sends a WeChat public-account article link starting with https://mp.weixin.qq.com. Line L087 explicitly states that non-public-account links can also be handled in the Feishu-writing path if the user asks to process them 'as the WeChat version,' which expands the documented behavior beyond the manifest’s declared scope.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
96% confidence
Finding

The instruction '语言:简体中文' imposes a fixed language requirement in the generated sprout report. There is no opt-in, user choice, or stated regional/compliance reason for this locale constraint, which makes it a natural-language policy violation under the language-choice rule.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.