Back to skill

Security audit

API Test Create

Security checks for vulnerabilities and agentic risk

Overview

This skill is a local API test-document generator, with no evidence of hidden data access, persistence, or external transmission.

Reasonable to install for local API test-planning use. Pin and audit PyYAML before production use, review generated test plans before acting on them, and run any suggested API, database, production-smoke, or load tests only in environments where you have authorization and rollback controls.

Vulnerability Patterns
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • 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
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (23)

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 · SKILL.md (reported line 295)May include surrounding context.

"username": "", // 空字符串 "username": "", // XSS "username": "admin'--", // SQL注入 "username": "../../etc/passwd" // 路径遍历 }

text

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/generate-checklist.py (reported line 451)May include surrounding context.

python
"username": "",  // 空字符串
  "username": "<script>alert(1)</script>",  // XSS
  "username": "admin'--",  // SQL注入
  "username": "../../etc/passwd"  // 路径遍历
}
```

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This markdown file presents all usage instructions, examples, and support text exclusively in Chinese. Under the policy, forcing a specific language without offering the user a language or locale choice is a natural-language policy violation.

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.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The manifest description is written as a directive in Chinese and presents the skill's use conditions and behavior only in that language. Under the policy, language or locale constraints should either be optional for the user or clearly justified as region-specific; neither is present here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest declares a fixed language value of "zh-CN", which indicates the skill is constrained to a specific language/locale. The file does not mention any user choice, opt-in, or justification for this locale restriction, which matches the policy-violation category for forced language settings.

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/openapi-example.yaml (reported line 7)May include surrounding context.

yaml
version: 1.0.0
  description: 用户注册、登录、信息管理的RESTful API
servers:
  - url: https://api.example.com/v1
    description: 生产环境
  - url: https://staging-api.example.com/v1
    description: 预发布环境

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

This markdown file presents all instructions, examples, and usage guidance exclusively in Chinese. Under the policy rule for natural-language violations, forcing a specific language without user opt-in or documented justification is a reportable issue.

Content

No source excerpt is available for this finding.

Unbounded Resource Access

Medium
Category
Excessive Agency
Confidence
75% confidence
Finding

Skill allows unbounded resource consumption (API calls, storage, compute). Without rate limits or quotas, a compromised or misbehaving agent can cause denial-of-service or cost overruns.

Content

Scanner excerpt · references/test-case-design.md (reported line 562)May include surrounding context.

md
# 支付场景网络中断
    # 在请求发送过程中中断网络
    try:
        response = api_client.post("/api/payment", {"order_id": "ORDER_123"}, timeout=0.1)
    except TimeoutError:
        # 查询支付状态
        status_response = api_client.get("/api/payment/ORDER_123/status")

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

This code file contains natural-language strings that present the tool exclusively in Chinese, including the top-level module description. Under the policy, forcing a specific language without offering a language choice or documenting a justified regional scope is a violation.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

_analyze_response 的注释和输出内容表明它在“分析响应验证”,且表格中明确写着“字段类型 | 每个字段匹配规格”,但实现并未读取 operation 或 spec 中的任何响应 schema,而是硬编码了 code/message/data、200/201、401/403/404/500 等通用检查项。这不是简单的信息不全,而是文档性描述与实际行为相矛盾:它看起来像基于接口规格生成,实际上并未依据具体规格分析响应。

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

函数注释为“分析安全测试”,在整体流程中被作为每个接口的“安全测试分析”部分调用,但实现完全不参考 operation、spec 或接口描述,始终输出 Token、RefreshToken、越权、SQL 注入等固定场景。这会让技能看似依据输入接口规格生成定制化安全分析,实际却是静态模板输出,和其文档化意图存在明显偏差。

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

Line L374 explicitly says '统一使用中文文档', which imposes a specific language choice in the skill materials. Under the policy, forcing a language or locale without user opt-in is a natural-language policy violation unless clearly justified or optionality is offered.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

This manifest contains user-facing titles, descriptions, and operation summaries in Chinese throughout, which effectively forces a specific language for consumers of the skill. The file does not indicate that the API is region-specific or provide any opt-in or alternative locale, so it may violate language/locale policy expectations.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

该 markdown 文件标题及全部内容均以中文呈现,没有说明这是面向特定中文团队或区域,也没有提供用户可选择的语言/locale。根据规则,强制特定语言而无用户选择可能构成自然语言层面的语言策略问题。

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

This markdown file contains user-facing instructional content exclusively in Chinese, starting from the title and continuing throughout the document. Under the policy rule for natural-language violations, forcing a specific language without user opt-in can be a locale policy issue when no scope limitation or language choice is provided.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

L628-L629 将该示例描述为 test_sensitive_info_encryption(api_client),看起来只进行接口层面的敏感信息加密测试;但 L659-L661 实际直接查询数据库,并使用函数签名中不存在的 db_client。这不是简单的实现细节缺失,而是文档/示例接口与实际代码行为不一致,会误导使用者对所需能力和依赖的理解。

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
96% confidence
Finding

The dependency is specified as PyYAML>=6.0 without an upper bound or exact pin, which makes builds non-reproducible and allows future installs to resolve to unexpected versions. In a security-sensitive workflow that processes user-supplied OpenAPI/Swagger YAML, this increases supply-chain and patch-state uncertainty, though by itself it is not direct code execution.

Content

Scanner excerpt · requirements.txt (reported line 4)May include surrounding context.

text
# API测试分析文档生成器依赖

# YAML解析(可选,用于OpenAPI YAML格式)
PyYAML>=6.0

# 日志和调试(内置模块,无需额外安装)
# logging - Python内置

Unverifiable Dependency: PyYAML has 8 known advisory(ies) (CVE-2019-20477 (Deserialization of Untrusted Data in PyYAML); CVE-2020-1747 (Improper Input Validation in PyYAML); CVE-2020-14343 (Improper Input Validation in PyYAML) +5 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
92% confidence
Finding

PyYAML has a history of security advisories, and because the manifest does not pin a specific version, it is impossible to verify whether deployments will use a patched release. This skill explicitly accepts OpenAPI/Swagger input and may therefore parse attacker-controlled YAML, making uncertainty around the installed PyYAML version more concerning than in a purely internal-only tool.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
83% confidence
Finding

_analyze_performance 注释为“分析性能测试”,且在每个接口分析中调用,容易让人理解为基于接口特征得出的性能测试分析。但实现没有读取任何接口规格、优先级或负载特征,只输出固定的响应时间门槛和并发场景模板,因此其说明性意图与实际行为不一致。

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

SQP-3 applies to all file types and covers language/locale policy violations in natural-language content. This file presents its documentation and later user-facing strings only in Chinese, with no indication that the skill is region-specific or that users can opt into that locale.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
89% confidence
Finding

The main block emits multiple user-visible labels in Chinese only. Under SQP-3, hard-coded locale-specific output can be a policy concern when the file does not offer a language choice or justify the restriction as region-specific.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
92% confidence
Finding

This Python test file contains natural-language docstrings and comments exclusively in Chinese, including the primary file description and class documentation. Under the policy, forcing a specific language without user opt-in or a documented regional justification is a natural-language policy concern.

Content

No source excerpt is available for this finding.