Back to skill

Security audit

文档导航服务

Security checks for vulnerabilities and agentic risk

Overview

This skill appears to be a documentation helper, but it requires and stores a third-party API key for an unrelated XiaoBenYang service before it can answer documentation questions.

Install only if you trust the XiaoBenYang service and are comfortable giving this skill an XBY API key that will be stored locally in plaintext. Prefer using a limited-scope key, avoid reusing secrets, and delete or rotate the key if you uninstall the skill.

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

Lp3

Medium
Category
MCP Least Privilege
Confidence
96% confidence
Finding
The skill documents capabilities to read environment variables, write files, and access the network, yet declares itself as a simple documentation navigator without transparent permission disclosure. This creates a trust gap: users may provide secrets or approve execution without understanding that the skill can persist credentials locally and send data to external services.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
The skill claims to be an ANSYS Fluent documentation MCP server, but the documented behavior includes collecting an API key, persisting it to .env, and calling a third-party XiaoBenYang service associated with an unrelated '高考' domain. This mismatch is dangerous because it can mislead users into disclosing credentials and allowing outbound requests under false pretenses.

Intent-Code Divergence

High
Confidence
99% confidence
Finding
The workflow section includes an example call to search_schools, which is unrelated to Fluent documentation and strongly suggests the skill was repurposed from a different application. In security terms, this inconsistency increases the likelihood of unintended data handling, wrong API invocation, or deceptive behavior that tricks users into interacting with an unrelated service.

Intent-Code Divergence

Medium
Confidence
97% confidence
Finding
The API key instructions and project references point to XiaoBenYang/高考 infrastructure rather than ANSYS Fluent documentation. This contradiction makes the skill context more dangerous because a user seeking harmless docs navigation would not reasonably expect their credential to be stored for an unrelated external service.

Description-Behavior Mismatch

Medium
Confidence
93% confidence
Finding
A skill described as simple official-document URL navigation should not unexpectedly depend on a third-party API key and remote service unless that dependency is explicitly justified. Hidden complexity expands the attack surface and can cause users to share secrets or route queries through an external system they did not intend to use.

Description-Behavior Mismatch

High
Confidence
97% confidence
Finding
This module provides the ability to persist, mutate, and retrieve an API key even though the declared skill is only for documentation navigation. That mismatch expands the trust boundary: a seemingly low-risk doc-navigation skill gains secret-handling capability, which can lead to credential exposure or unauthorized service use if the skill is installed or invoked under false assumptions.

Context-Inappropriate Capability

High
Confidence
96% confidence
Finding
Writing API keys into a local .env file creates plaintext at-rest secret storage, which is unnecessary for a documentation-navigation service and increases the chance of leakage through backups, source control, local compromise, or accidental sharing. The risk is elevated because the capability is not justified by the skill's stated purpose, so users may not expect secret persistence.

Intent-Code Divergence

Medium
Confidence
88% confidence
Finding
The settings docstring identifies the code as belonging to a different skill than the manifest, which is a supply-chain trust signal problem. In the context of a documentation-navigation skill, mismatched identity suggests code reuse, repackaging, or incomplete review, making hidden or unjustified capabilities like credential handling more suspicious and dangerous.

Missing User Warnings

Medium
Confidence
98% confidence
Finding
The skill explicitly instructs the agent to ask the user for an API key and save it via set_api_key(api_key), but gives no warning that the key is sensitive, will be persisted locally, or may be used for future network calls. That creates a secret-handling risk and may lead to unnecessary collection or insecure storage of credentials.

Missing User Warnings

Medium
Confidence
94% confidence
Finding
The code persists an API key to .env without any user-facing warning, consent flow, or disclosure. Silent secret persistence is dangerous because users may assume a one-time in-memory use while the key is actually stored on disk in plaintext, increasing the chance of accidental exposure.

Credential Access

High
Category
Privilege Escalation
Content
default_year: int = 2025

    def model_post_init(self, __context):
        # 强制从 .env 文件读取 XBY_APIKEY
        env_path = Path(".env")
        if env_path.exists():
            content = env_path.read_text(encoding="utf-8")
Confidence
95% confidence
Finding
The code manually opens and parses .env to extract XBY_APIKEY, which is direct credential access logic. In a skill whose stated role is merely documentation navigation, this is an unjustified secret-handling capability and increases the risk of misuse, accidental disclosure, or hidden collection of credentials.

Credential Access

High
Category
Privilege Escalation
Content
def model_post_init(self, __context):
        # 强制从 .env 文件读取 XBY_APIKEY
        env_path = Path(".env")
        if env_path.exists():
            content = env_path.read_text(encoding="utf-8")
            for line in content.splitlines():
Confidence
95% confidence
Finding
Creating a Path to .env and reading it as part of custom initialization is part of explicit credential access behavior. Because the skill context does not justify secret management, this access is more dangerous than it would be in a clearly authenticated integration, and it undermines the expected low-risk profile of a documentation tool.

Credential Access

High
Category
Privilege Escalation
Content
def save_api_key_to_env(api_key: str) -> bool:
    """将API key保存到.env文件"""
    try:
        env_path = Path(".env")
        lines = []
        if env_path.exists():
            lines = env_path.read_text(encoding="utf-8").splitlines()
Confidence
96% confidence
Finding
This function explicitly saves an API key into .env, creating plaintext credential storage on disk. In the context of a documentation-navigation skill, such secret persistence is unjustified and significantly increases exposure risk through file leakage, developer tooling, backups, or repository mistakes.

Credential Access

High
Category
Privilege Escalation
Content
def set_api_key(api_key: str) -> bool:
    """设置API key并持久化到.env"""
    if not api_key or not api_key.strip():
        return False
    api_key = api_key.strip()
Confidence
96% confidence
Finding
This function sets an API key and persists it to .env, combining secret mutation with durable storage. That capability is high risk here because it allows a nominally simple documentation skill to collect and retain credentials locally without a clear, necessary product reason.

Unpinned Dependencies

Low
Category
Supply Chain
Content
requests>=2.31.0
pydantic>=2.7.0
pydantic-settings>=2.2.0
python-dotenv>=1.0.1
Confidence
96% confidence
Finding
The dependency is specified with a lower bound only, which allows future installs to resolve to different versions over time. That weakens build reproducibility and can unintentionally pull in vulnerable or breaking releases, which is a real supply-chain risk even though it is not immediately exploitable by itself.

Unpinned Dependencies

Low
Category
Supply Chain
Content
requests>=2.31.0
pydantic>=2.7.0
pydantic-settings>=2.2.0
python-dotenv>=1.0.1
Confidence
96% confidence
Finding
Using pydantic>=2.7.0 permits uncontrolled upgrades to newer releases, reducing reproducibility and increasing exposure to future vulnerable versions. In a server-side skill, dependency drift can change parsing and validation behavior unexpectedly and complicate incident response.

Unpinned Dependencies

Low
Category
Supply Chain
Content
requests>=2.31.0
pydantic>=2.7.0
pydantic-settings>=2.2.0
python-dotenv>=1.0.1
Confidence
95% confidence
Finding
A minimum-only version constraint for pydantic-settings allows installations to vary over time and may introduce vulnerable or incompatible releases without code changes. This is a genuine supply-chain hygiene issue, though the direct impact is limited unless a bad version is later resolved.

Unpinned Dependencies

Low
Category
Supply Chain
Content
requests>=2.31.0
pydantic>=2.7.0
pydantic-settings>=2.2.0
python-dotenv>=1.0.1
Confidence
95% confidence
Finding
python-dotenv>=1.0.1 is unpinned, so deployments may consume different versions depending on install time and index state. That can silently introduce vulnerable releases or behavioral changes into an MCP server environment.

Known Vulnerable Dependency: requests==2.31.0 — 3 advisory(ies): CVE-2024-47081 (Requests vulnerable to .netrc credentials leak via malicious URLs); CVE-2024-35195 (Requests `Session` object does not verify requests after making first request wi); CVE-2026-25645 (Requests has Insecure Temp File Reuse in its extract_zipped_paths() utility func)

Low
Category
Supply Chain
Confidence
93% confidence
Finding
The requirements allow requests 2.31.0, which is flagged with multiple advisories including credential leakage via malicious URLs and session verification issues. Because this skill is a document-navigation MCP server likely to fetch remote URLs, the context makes requests flaws more relevant than in an offline tool: SSRF-like inputs or attacker-controlled links could expose credentials or weaken transport guarantees.

Known Vulnerable Dependency: python-dotenv==1.0.1 — 1 advisory(ies): CVE-2026-28684 (python-dotenv: Symlink following in set_key allows arbitrary file overwrite via )

Low
Category
Supply Chain
Confidence
82% confidence
Finding
python-dotenv 1.0.1 is reported vulnerable to symlink-following behavior in set_key that could enable arbitrary file overwrite if an attacker can influence dotenv file paths or filesystem links. In this skill's stated role, dotenv is likely used for configuration loading rather than key-writing, so exploitability depends on whether set_key or similar write operations are actually used; the context makes it less dangerous than the requests issue but still worth remediating.

Static analysis

No suspicious patterns detected.