Back to skill

Security audit

qa-test-skills

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent QA test-case workflow, but it can automatically read/fetch broad referenced documents and run a local validation command without enough scoping or confirmation.

Review before installing if you will use it on private repositories or sensitive requirement documents. Only provide documents from trusted sources, avoid letting it follow arbitrary embedded paths or directories, confirm any URL fetches, and inspect or pin the install source before running the npx command.

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

T09 · Insecure Skill Coding Practices

Warning
Location
references/routing.md:36
Finding

Unrestricted Local File Inclusion Through Document References

Content
View full analysis

Vulnerability Details

File Location: references/routing.md, lines 36–62
Vulnerability Type: Unrestricted local-file inclusion
Risk Level: Medium

Vulnerable Instructions

text
步骤2:解析文档中的索引引用
  - 查找对子模块需求的引用(如"详见 requirements/01-auth.md")
  - 查找目录结构(如"需求文档目录:docs/requirements/")
  - 查找链接引用(如"[认证需求](./requirements/01-auth.md)")
  - Word文档中的目录引用(如"认证模块需求见附件01-auth.docx")
步骤3:读取所有被引用的子模块需求文档
  - 支持混合格式(主文档是Word,子模块是Markdown等)
步骤4:合并所有需求内容进行分析
text
**识别模式**:
- 相对路径引用:`./requirements/01-auth.md`、`../requirements/01-auth.md`
- 绝对路径引用:`/docs/requirements/01-auth.md`
- 目录引用:`requirements/`、`docs/requirements/`
- 锚点引用:`#认证模块`、`##用户管理`
- 附件引用:`附件01-auth.docx`、`详见附件`
- 跨格式引用:`认证需求见 requirements/01-auth.md`

**处理原则**:
- 主文档包含索引时,必须读取所有被引用的子模块
- 子模块需求是主文档的补充,不能忽略
- 支持混合格式(主文档和子模块可以是不同格式)
- 合并所有需求后,再进行后续的测试设计流程

Technical Analysis

The workflow treats paths embedded in an imported requirements document as trusted file-selection instructions. It explicitly recognizes relative paths, parent-directory references, absolute paths, and directory references, then requires the Agent to read every referenced document and merge its contents into the testing context.

No instruction constrains resolved paths to the directory containing the user-selected requirements document. There is also no canonical-path validation, symlink check, path allowlist, or separate user confirmation for files discovered through document content.

Consequently, an independently supplied or modified requirements document can direct an Agent with Read access toward unrelated local files. This crosses the authorization boundary between the document the user selected and other files accessible to the Agent.

Attack Path

  1. An attacker creates or modifies a requirements document that a victim imports into the Skill.
  2. The attacker embeds a reference to an unrelated local path, such as a parent-directory path, absolute path, or directory reference.
  3. The Skill follo ...[truncated 1216 chars]
Remediation
View remediation

Remediation Suggestions

  1. Establish an explicit document root from the file or directory selected by the user.
  2. Canonicalize every discovered reference before opening it.
  3. Reject absolute paths and any relative path whose canonical destination falls outside the authorized document root.
  4. Detect and reject symbolic-link escapes from the authorized root.
  5. Do not recursively read entire directories merely because an imported document names them.
  6. Maintain an allowlist of supported document extensions and reject device files, sockets, and other non-regular files.
  7. Present files discovered through document references to the user and require explicit approval before reading anything outside the initially selected set.
  8. Track reference depth and visited files to prevent recursive-reference loops.
  9. Keep unrelated file contents out of generated prompts and reports, and apply output redaction for recognized secrets as a defense-in-depth measure.
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (13)

Vague Triggers

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The trigger conditions are extremely broad (生成测试用例, 帮我测试, 设计测试, 上传需求, 开始测试, 获取安装指引时) and overlap with common user requests, increasing the chance of unintended skill activation. Because this skill is an orchestration entrypoint that can invoke many subskills, read references, and direct tool usage, accidental activation can cause excessive processing, incorrect routing, or unreviewed downstream actions.

Content

No source excerpt is available for this finding.

Vague Triggers

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The metadata when-to-use field repeats broad automatic activation rules, including generic requests and document uploads, which can trigger the workflow in contexts where the user did not intend a full 12-step process. In this skill, the danger is amplified by strong execution language ('自动激活', mandatory steps, tool usage, installation guidance), making misrouting and overbroad task expansion more likely.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The manifest description and behavior instructions are written to operate in Chinese, while also embedding an English sentence, but there is no statement that users may choose their preferred language. This can violate language/locale policy expectations when a skill implicitly forces one language without opt-in.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
91% confidence
Finding

The skill instructs users to run npx skills add Kokxi/qa-test-skills without pinning an exact version or immutable reference. That makes installation depend on the latest package state at execution time, creating a supply-chain risk where a compromised or changed upstream package could execute unintended code or install altered skill content.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

This markdown file is entirely written as prescriptive guidance to the AI in Chinese, including statements about how the AI should judge complexity and generate outputs. Under the policy, forcing a specific language or locale without user opt-in is a natural-language policy violation unless the constraint is explicitly documented and justified as region-specific, which is not stated here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The entire enforcement document is written as a mandatory instruction set in Chinese and states the agent must strictly follow it, but it does not provide any user opt-in or alternative language handling. Under the policy, forcing a specific language without user choice is a natural-language policy violation unless the locale restriction is explicitly justified.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The manifest describes a skill intended to generate structured test cases from requirement documents such as PRD, Word, PDF, or URL inputs. Lines L09-L11 instead impose a global ban on reading code implementations except for special cases, creating documentation-level intent divergence because the skill's documented operational constraint is about code review avoidance rather than the manifest's declared requirements-document workflow.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The entire template and instructions are written as a prescriptive output format in Chinese, with no indication that users may choose another language or locale. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale restriction is explicitly justified.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The routing rules explicitly direct the skill to fetch remote URLs and read files or directories, but they do not require user confirmation, scope restriction, or a warning that external/network access and broad document ingestion may occur. In an agent skill, this can cause unintended retrieval of sensitive local or remote content and expands the attack surface through unbounded input resolution.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The workflow mandates reading all referenced submodule documents and merging them automatically, including mixed-format and directory references, without a user-visible notice or approval step. This recursive expansion can be abused to pull in unintended documents, amplify prompt injection exposure from referenced content, and cause overcollection of sensitive data beyond what the user expected to submit.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

该 markdown 文件的自然语言说明从标题到正文均固定为中文,且未见任何允许用户选择语言、双语支持或对中文限定场景的说明。根据规则,未获用户选择或缺乏明确合理化的语言/地区限制,属于自然语言策略违规。

Content

No source excerpt is available for this finding.

Skill Enumeration

Medium
Category
Agent Snooping
Confidence
80% confidence
Finding

Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.

Content

Scanner excerpt · references/workflow-detail.md (reported line 3)May include surrounding context.

md
# 工作流详细执行指南

> 本文档是 `skills/qa-test-skills/SKILL.md` 中标准化工作流的详细展开,包含每步的输入/输出/执行内容/输出格式。
> 需要在执行某步时遇到疑问时查阅,不作为主流程的直接执行指令。

---

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
78% confidence
Finding

The policy requires flagging language or locale constraints when a skill forces a specific language without user opt-in. This routing document presents all instructions and trigger vocabulary solely in Chinese, with no indication that users may choose another language or that the Chinese-only scope is intentional and justified.

Content

No source excerpt is available for this finding.