Back to skill

Security audit

static-deploy

Security checks for vulnerabilities and agentic risk

Overview

This is a real static-site deployment helper, but it needs Review because it can publish local files publicly and persist free-form deployment history without enough confirmation or privacy boundaries.

Review the exact directory and target before allowing this skill to deploy anything, and do not rely on its sensitive-file check as a complete secret scan. Prefer pinned deployment tooling over the documented unpinned npx command. Treat learned_patterns.json as local telemetry that may contain sensitive notes or URLs, and clear or avoid it if that data should not persist.

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 (3)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/deploy_check.py:6
Finding

Incomplete sensitive-file detection can approve credential-containing deployment artifacts

Content
View full analysis
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
SKILL.md:40
Finding

Unpinned remote package execution in the documented Netlify deployment workflow

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Note
Location
scripts/learner.py:86
Finding

Persistent unsanitized notes can be replayed as Agent-visible recommendation text

Content
View full analysis
= THRESHOLD_ERROR: suggestions.append( f"⚠️ 错误「{err}」已出现 {info['count']} 次,建议增加预检/兜底步骤," f"并将经验回写本技能 SKILL.md(lastNote: {info.get('lastNote','')})" ) ``` ### Technical Analysis The `--note` argument is accepted as arbitrary text and persisted in `learned_patterns.json`. Once an error reaches the reflection threshold, the stored text is interpolated directly into an Agent-visible recommendation that also suggests writing experience back into `SKILL.md`. The script does not distinguish trusted instructions from untrusted historical data. It also does not itself modify `SKILL.md`, so this is not an automatic persistent instruction rewrite. Nevertheless, crafted text can survive across runs and later appear in a context where an Agent may interpret it as an instruction. ### Attack Path 1. An attacker or untrusted automation can influence the value passed through `--note`. 2. The same error is recorded at least three times, reaching `THRESHOLD_ERROR`. 3. The note is stored persistently in `learned_patterns.json`. 4. A later invocation runs `python scripts/learner.py reflect ...`. 5. The crafted note is emitted inside a recommendation that references updating `SKILL.md`. 6. If an Agent fails to treat the note as untrusted data, it may follow the injected text or persist it into Skill instructions. ### Impact Assessment Successful exploitation could influence later Agent behavior or ...[truncated 472 chars]
Remediation
View remediation
Vulnerability Patterns
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • 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
Findings (15)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

该代码与声明有部分重合之处:确实实现了“构建产物校验”。但声明的核心范围明显更广,强调这是一个“部署助手”,并列举了多个具体平台的发布流程;而提供的代码片段完全没有网络请求、平台 API 调用、文件上传、发布配置生成或任何部署相关操作。其实际主功能只是部署前检查,因此对技能整体能力的描述存在实质性夸大,属于描述与行为不一致。

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

声明描述聚焦于静态网站部署与发布流程,但提供的代码块完全没有部署相关行为,例如检查构建产物、调用任何部署平台 API、上传文件、生成部署配置或触发发布。相反,它实现的是一个与具体业务无关的“自进化学习模块”,对任意技能的使用情况进行本地 JSON 持久化、统计分析和复盘建议输出。这属于与声明主用途 materially different 的功能,因此应判定为明显不匹配。

Content

No source excerpt is available for this finding.

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 · scripts/deploy_check.py (reported line 6)May include surrounding context.

python
import argparse, json, os, sys


SUSPICIOUS = (".env", "credentials", "id_rsa", "secret", ".pem", "key.json")


def check(dist_dir):

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The file implements a generic cross-skill telemetry and self-learning module that is unrelated to a static-site deployment assistant's declared purpose. In this context, unnecessary cross-cutting persistence increases the attack surface and creates a covert channel for collecting and retaining usage data that users would not reasonably expect from a deployment helper.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The trigger phrases are broad enough to activate on common requests like 'deploy website' or 'publish frontend,' increasing the chance the skill is invoked in contexts where its assumptions or side effects are inappropriate. In a deployment skill, overbroad routing can lead to accidental publication actions, use of external tools, or exposure of files that were not meant to be deployed.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The skill content and user-facing description are entirely in Chinese, and there is no indication that the user can choose another language or that the skill is intended only for a Chinese-language audience. This can violate language/locale policy where skills must not force a specific language without user opt-in.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

The skill presents a default path that can deploy a local directory and return a public URL, which is an externally impactful action. Without an explicit user confirmation gate and clear checks for sensitive content, autonomous selection of deployment targets increases the risk of accidental data exposure or unintended publication.

Content

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

md
| CloudStudio 沙箱 | 任意静态目录,免配置,国内可达 | `workbuddy_cloudstudio_deploy` 工具 |
| EdgeOne Pages | 国内加速、绑定域名 | `edgeone-pages-deploy` 技能 |
| Netlify / Vercel | 海外、CI 友好、自动 HTTPS | CLI / Git 集成 |
| GitHub Pages | 开源项目页、文档站 | `github-pages-auto-deploy` 技能 |

> WorkBuddy 已内置 `workbuddy_cloudstudio_deploy` 工具,可直接把本地目录部署到 CloudStudio 沙箱并返回访问 URL——这是最省心的默认路径。

Rp1

Medium
Category
MCP Rug Pull
Confidence
89% confidence
Finding

Using npx netlify-cli without pinning a version can pull the latest package at execution time, introducing supply-chain risk and nondeterministic behavior. If the upstream package or dependency chain is compromised, the skill could cause execution of attacker-controlled code during deployment.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

The workflow directs the agent to choose a default deployment target and execute publishing steps, including external hosting and post-deploy validation, with limited mention of approval boundaries. In the context of a public deployment skill, this autonomy is more dangerous because mistakes can immediately expose internal artifacts, reports, or bundled secrets to the internet.

Content

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

md
- **默认(最快)**:调用 `workbuddy_cloudstudio_deploy`,目录填构建输出目录(如 `dist/`)。
- **国内加速**:用 `edgeone-pages-deploy` 技能,支持自定义域名。
- **海外/CI**:Netlify/Vercel CLI(`npx netlify-cli deploy --prod --dir dist`)。
- **开源文档**:`github-pages-auto-deploy`。

### 3. 发布后验证
- 拿到 URL 后用 `web-fetch` 技能抓取首页,确认状态码 200 且关键内容存在。

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The module docstring is written entirely in Chinese, and the script's user-facing messages are also Chinese-only, indicating the skill is designed for a single language without user opt-in. Under the policy, forcing a specific language is a natural-language policy violation unless the locale restriction is explicitly justified or optional.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

Multiple user-visible strings such as error and status messages are hardcoded in Chinese, and there is no mechanism for language selection. This creates a locale policy issue because the skill forces one language for all users without presenting a choice or stating a justified regional constraint.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The module description, usage text, and user-facing messages are written entirely in Chinese, which imposes a specific language experience by default. The policy allows locale constraints only when they are documented and justified or when the user is given a choice, neither of which appears here.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The script persistently records per-skill operational history, error notes, and user preferences to disk, which exceeds what a static deployment assistant needs to perform deployments. Because note and preference fields are free-form, users or calling components may unintentionally store secrets, internal paths, tokens, or other sensitive operational details that remain on disk for later access.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The code writes user preferences and free-form notes directly into learned_patterns.json without any explicit notice, consent flow, or privacy boundary. This is dangerous because notes can easily contain sensitive deployment information, and undisclosed local persistence creates confidentiality and compliance risks even if the data never leaves the machine.

Content

No source excerpt is available for this finding.