Back to skill

Security audit

Nodecoda Workflow - Dify

Security checks for vulnerabilities and agentic risk

Overview

The skill’s workflow purpose is legitimate, but it repeatedly asks agents to run an unpinned npm package that can install MCP configuration, access credentials, send source to remote services, and run again in future sessions.

Review before installing. The main issue is not that NodeCoda builds workflows remotely, but that the skill normalizes running a mutable, unpinned npm package with local filesystem, environment, credential, and MCP-startup access. Prefer an exact pinned version, a reviewed local install, narrowly scoped `workflow:build` credentials, and avoid passing account email/password to a package fetched at runtime.

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

T08 · Insecure Dependencies

Error
Location
SKILL.md:24
Finding

Unpinned Third-Party Package Is Downloaded and Executed with Access to Source Files and Credentials

Content
View full analysis
` 修复,或按 `docs/installation.md` / `.codex/config.example.toml` 手动接线; 4. **不要假装已具备能力**:工具缺失时报告安装指引,而不是绕过 MCP 猜测行为;此时可立即改用 `npx -y @nodecoda/skill build ` 完成构建(无需 MCP 客户端、无需 key),不必等重启。 ``` `SKILL.md:69-75`: ```markdown > 1. **CLI 直连构建(最省事,无需 MCP 客户端、无需 key)** — `npx -y @nodecoda/skill build `: > 自动选路(无 `NODECODA_KEY` → try.nodecoda.com guest JSON-RPC;有 `NODECODA_KEY` → www REST), > 提交 → 轮询到终态 → SUCCEEDED 自动把 Dify Workflow artifact + build 记录 > 平铺覆盖落盘到源文件同目录(`.dify.yaml` 等,不建 build_id 目录、 > 无 source 副本,版本交给 git)。其余 flag:`--target` / `--idempotency-key` / > `--out` / `--no-save` / `--timeout-ms` / `--dry-run` / `--json`。 > 2. 有 key 时走「公共部署 · REST 直连回退」curl 配方(见下),凭据只从环境读取。 ``` `SKILL.md:304-306`: ```bash NODECODA_EMAIL=... NODECODA_PASSWORD=... npx -y @nodecoda/skill live-mcp # 已有 sk-... 时 NODECODA_KEY=sk-... npx -y @nodecoda/skill live-mcp ``` `references/public-service.md:148`: ```markdown 零安装形式:`command = "npx"`、`args = ["-y", "@nodecoda/skill", "mcp"]`——Codex 会话启动时按需拉取 npm 包,无需 clone 或本地安装(`--http [--port N]` 则起 Streamable HTTP 传输)。stdio/HTTP server 把 3 个 MCP 工具(`build_dify_workflow` / `get_workflow_build` / `cancel_workflow_build`)转给 **MCP gateway base**(默认 `https://www.nodecoda.com/v1`——注意不是 `/api/v1` admin base,后者只收 JWT 管理凭证、拒绝 `sk-` key)。读 `NODECODA_KEY` 环境变量(或客户端 Bearer 透传);未设置时工具调用返回 `NO_KEY` 而不是崩溃。 ``` ### Techn ...[truncated 3334 chars]
Remediation
View remediation
Vulnerability Patterns
  • 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
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (94)

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- [失败处理](references/failure-modes.md)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
80% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · references/public-service.md (reported line 65)May include surrounding context.

md
- `POST /mcp`:JSON-RPC 2.0 请求,响应 `application/json`;无状态 server,不签发 `Mcp-Session-Id`。notification 返回 `202` 空响应。
- `GET /mcp`(`Accept: text/event-stream`):SSE 通道,仅心跳(15s keep-alive);server 无会话,不做 server push。
- `OPTIONS /mcp`:CORS 预检(`Access-Control-Allow-Origin: *`)。
- `DELETE /mcp`:`405`(无状态 server,无会话可终止)。
- 认证:客户端 `Authorization: Bearer <sk-...>` 原样透传给上游 Workspace REST;缺失且未设 `NODECODA_KEY` 时返回 `401` JSON-RPC error(`-32001`)。

> ⚠️ **本节只描述 www.nodecoda.com 生产端 `/mcp`(key 路径,无状态)**。try.nodecoda.com

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
80% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · references/public-service.md (reported line 65)May include surrounding context.

md
- `POST /mcp`:JSON-RPC 2.0 请求,响应 `application/json`;无状态 server,不签发 `Mcp-Session-Id`。notification 返回 `202` 空响应。
- `GET /mcp`(`Accept: text/event-stream`):SSE 通道,仅心跳(15s keep-alive);server 无会话,不做 server push。
- `OPTIONS /mcp`:CORS 预检(`Access-Control-Allow-Origin: *`)。
- `DELETE /mcp`:`405`(无状态 server,无会话可终止)。
- 认证:客户端 `Authorization: Bearer <sk-...>` 原样透传给上游 Workspace REST;缺失且未设 `NODECODA_KEY` 时返回 `401` JSON-RPC error(`-32001`)。

> ⚠️ **本节只描述 www.nodecoda.com 生产端 `/mcp`(key 路径,无状态)**。try.nodecoda.com

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The manifest says the skill operates through an authenticated MCP service, but the body adds unauthenticated guest access and direct CLI/REST fallbacks. This mismatch can mislead users and agents about where data is sent and what trust assumptions apply, causing unintended disclosure of workflow source or metadata to alternate services.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

This markdown file contains core user-facing operating instructions in Chinese, but does not indicate that the user can choose another language or that Chinese is required for a justified region-specific purpose. That creates a natural-language policy issue because the skill effectively imposes a locale/language on users without opt-in.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The skill repeatedly instructs the agent to execute npx -y @nodecoda/skill without pinning an exact package version. This allows whatever package version is current in the registry at execution time to run with the agent's local privileges, creating a supply-chain execution risk if the package is updated maliciously or compromised.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The skill claims an MCP-centered purpose but instructs the agent to run local npm/node commands to install, register, and directly build artifacts. This expands the execution surface from controlled tool use to arbitrary local command execution, increasing the chance of filesystem changes, unexpected network activity, or code execution outside the declared trust boundary.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

This line invokes an unpinned npm package as an operational fallback, which means the agent may download and execute new code from the registry during a task. In a skill context, that turns documentation into a remote code execution path controlled by upstream package publication state.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

Using npx -y @nodecoda/skill here again leaves the executed code version unspecified. An attacker controlling or poisoning the package supply chain could cause arbitrary commands or data access when the agent follows the skill instructions.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

This project command relies on a floating package version fetched via npx, exposing the environment to unexpected or malicious upstream changes. Because the skill normalizes repeated use of these commands, it broadens the attack surface and makes compromise more likely over time.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The restore workflow also depends on an unpinned package execution path. Even read-like operations can execute arbitrary package install hooks or command logic, so the risk is not limited to explicit build actions.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

This state-transition command uses the same unpinned npx pattern, enabling arbitrary code execution through package substitution or compromise. The repetition suggests the unsafe practice is systemic rather than incidental.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The save-build command is another instance of executing remote npm code without version control. A compromised package could access local files, environment variables, or alter outputs while appearing to perform routine archival work.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The skill's lightweight or helper workflow still executes an unpinned package, keeping the same supply-chain risk present across all modes. Since skills are often followed automatically, users may not realize these commands fetch fresh code at runtime.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The login/upgrade guidance references the same unpinned package execution pattern. This is dangerous because credential-related flows are especially sensitive and should not depend on mutable code fetched at runtime.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The end-to-end validation script uses npx -y @nodecoda/skill without pinning, so even testing paths can execute unreviewed upstream code. This undermines trust in the whole workflow and creates a broad supply-chain attack vector.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

This example again fetches and runs a mutable npm package at execution time. In a security-sensitive agent environment, that is equivalent to authorizing remote code execution from the package registry.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The second adjacent invocation repeats the unpinned execution pattern, reinforcing a dangerous operational norm. Any compromise of the published package could affect all users following the documented fallback flow.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
89% confidence
Finding

The skill includes direct curl instructions that transmit workflow source and authorization headers to an external service. Even if intended, this is security-relevant because it bypasses the declared MCP-only boundary, enables manual exfiltration paths, and increases the risk of sending sensitive source or tokens through less-controlled operational flows.

Content

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

bash
# 1) 提交 Build —— 关键:idempotency_key 必须「body 内」和「Idempotency-Key 请求头」各一份,
#    只放 body 会返回 400 WORKFLOW_BUILD_REQUEST_INVALID(实证 2026-08-14)。
curl -sS -X POST https://www.nodecoda.com/v1/workflow-builds \
  -H "Authorization: Bearer $NODECODA_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: <project>-rev-<n>-<ts>" \

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The workflow forwards raw user input to an external LLM service without any disclosure, consent, or indication of data handling boundaries. In an authenticated MCP context, users may reasonably assume local/tool-scoped processing, so silent transmission to a third-party model can expose sensitive prompts, credentials, proprietary code, or personal data.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The system message instructs the model in Chinese and fixes the assistant behavior to respond in that language/style, with no indication that the user can choose another language. This creates a language-policy issue because the skill imposes a locale/language constraint without opt-in or justification.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

This workflow contains natural-language instructions in Chinese and explicitly prompts the model in Chinese for analysis and synthesis, which imposes a language choice regardless of user preference. The file does not offer any language selection or document a justified locale restriction, so it conflicts with the language/locale policy criteria.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The workflow sends the user-provided essay content to an external LLM service, which is a real privacy and data-handling concern when there is no explicit disclosure, consent flow, or indication of data minimization. In this skill context, using an LLM is expected, but silently transmitting potentially sensitive free-form text still creates exposure if essays contain personal, confidential, or regulated information.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

This code sends the user-provided query to an external LLM service at L12-L14 and performs an HTTP request to an external API at L17-L18. There is no visible confirmation prompt, user-facing logging, or explanatory comment disclosing these external network operations from a user-safety perspective.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · examples/06-error-handling.ncoda (reported line 17)May include surrounding context.

text
}) with retry(max: 3, interval: 1s);

    // attempt 捕获操作的物理失败(网络错误、超时等)
    attempt http("GET", "https://api.example.com/quote", {
        "headers": { "Accept": "application/json" }
    }) as page {
        success {