Back to skill

Security audit

图标集成服务

Security checks for vulnerabilities and agentic risk

Overview

This icon skill uses a third-party API and stores an API key locally, but several files still reference an unrelated school-service project, making the package too ambiguous for automatic approval.

Review this skill before installing. It may only be a poorly cleaned-up Hugeicons wrapper, but it asks for a XiaoBenYang API key, stores that key in plaintext .env, sends icon queries to a XiaoBenYang MCP endpoint, and includes leftover Gaokao/school-service references. Install only if you trust that publisher and are comfortable with that third-party service receiving the key and requested icon parameters.

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

Lp3

Medium
Category
MCP Least Privilege
Confidence
91% confidence
Finding
The skill documents capabilities to read environment variables, write local configuration, and make network calls, but does not declare those permissions. This creates a transparency and consent problem: users and host platforms cannot accurately assess what the skill can access before execution, and the hidden API-key persistence increases the risk of credential mishandling.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding
The declared skill purpose is Hugeicons integration, but the behavior described includes storing an external API key locally and routing requests to an unrelated third-party XiaoBenYang service. This mismatch is dangerous because it can mislead users into disclosing credentials and sending data to a different backend than expected, defeating informed consent and trust boundaries.

Intent-Code Divergence

High
Confidence
95% confidence
Finding
The workflow example instructs the model to call a school-search function unrelated to icon retrieval, indicating either copy-paste contamination or hidden cross-domain behavior. In a skill that asks for an API key and routes requests externally, such inconsistencies increase the risk that user prompts or secrets are sent to unintended tools or services.

Intent-Code Divergence

Medium
Confidence
88% confidence
Finding
Referencing an unrelated project directory name and mismatched API-key context suggests the skill package may be repurposed from another service without proper isolation. That raises the chance of accidental cross-service configuration reuse, credential confusion, or calls into the wrong codebase/backend.

Description-Behavior Mismatch

High
Confidence
95% confidence
Finding
The file implements a generic client for an external service identified as '小笨羊MCP API', which does not match the declared Hugeicons-only purpose of the skill. In a security-sensitive agent context, this mismatch can hide unexpected outbound data flows or invoke unintended third-party capabilities, increasing the risk of covert exfiltration, unauthorized actions, or supply-chain abuse.

Intent-Code Divergence

Medium
Confidence
89% confidence
Finding
The docstrings and naming indicate this code is meant to call '小笨羊MCP' tools rather than Hugeicons resources, which is a strong indicator of code repurposing or deceptive packaging. This inconsistency makes review and trust decisions harder and can conceal functionality that operators did not intend to deploy.

Description-Behavior Mismatch

High
Confidence
98% confidence
Finding
The configuration code is clearly for a different service/skill than the declared icon-integration skill: it references '小笨羊高考', uses XBY_GAOKAO_ prefixed settings, and persists an unrelated XBY_APIKEY. This mismatch is dangerous because users or reviewers may believe they are installing an icon utility while the code handles credentials for an unrelated external service, increasing the risk of unauthorized data flow or credential collection under false pretenses.

Context-Inappropriate Capability

Medium
Confidence
95% confidence
Finding
This code persists credentials for an unrelated external service into a local .env file, even though the skill is described as an icon integration service. Persisting unrelated secrets broadens the attack surface, may expose credentials through local files, source-control accidents, backups, or later reads by other components, and is especially suspicious given the manifest/code mismatch.

Missing User Warnings

Medium
Confidence
91% confidence
Finding
The function silently writes the supplied API key to .env and updates process environment state without any explicit user-facing warning, confirmation, or disclosure of persistence. This is dangerous because users may expect a transient session-only setting, while the key is actually stored in plaintext on disk where it may be exposed to other users, tools, backups, or accidental commits.

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
90% confidence
Finding
The code forcibly reads a specific API key directly from .env in custom logic, bypassing normal scoped configuration behavior and targeting a credential unrelated to the declared skill purpose. In context, this increases concern because the skill manifest does not justify collecting or loading this external-service secret, making the behavior deceptive and expanding secret exposure.

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
90% confidence
Finding
Reading the contents of .env directly enables broad access to locally stored secrets and is unnecessary when standard settings loading already exists. In this skill context, manually scanning the file for XBY_APIKEY is suspicious because it targets an unrelated credential not obviously needed for icon functionality.

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
93% confidence
Finding
This function is explicitly designed to save an API key into a plaintext .env file, creating persistent local secret exposure. In combination with the skill-purpose mismatch, this is more dangerous because it stores credentials for an unrelated service under the guise of a different tool, which can mislead users and reviewers.

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
92% confidence
Finding
The set_api_key workflow is specifically intended to set and persist a credential to disk for later reuse. Persisting external-service credentials without strong necessity, transparency, or secure storage increases the chance of leakage through local files, logs, backups, or repository mistakes, and is made more concerning by the mismatch between the skill's stated purpose and actual credential handling.

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
The dependency is specified with a lower bound only, which allows future installs to resolve to different versions over time. This weakens reproducibility and can unintentionally introduce breaking changes or newly published vulnerable releases into the environment.

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
Using an unpinned version for pydantic means builds are not deterministic and later installations may pull in unexpected versions. This increases supply-chain risk and can cause security or compatibility regressions without any code change in the skill 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
95% confidence
Finding
A minimum-only version specifier for pydantic-settings permits unreviewed newer releases to be installed. That creates reproducibility and supply-chain exposure because dependency behavior and security posture can change between installs.

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
The unpinned python-dotenv dependency allows the installed version to drift over time, potentially bringing in unvetted changes or vulnerable releases. In configuration-handling libraries, that can be especially risky because they often touch environment and filesystem behavior.

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
90% confidence
Finding
The requirement permits installation of requests 2.31.0, which is flagged with multiple advisories, including credential leakage and TLS verification-related issues in certain usage patterns. Even though the file uses a >= specifier rather than an exact pin, this range still includes a known vulnerable version, so environments may resolve to an unsafe release depending on installation state and constraints.

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
84% confidence
Finding
The dependency specification allows installation of python-dotenv 1.0.1, which is reported as vulnerable to symlink-following behavior in set_key that may enable arbitrary file overwrite in affected usage. The actual risk depends on whether the skill calls the vulnerable API on attacker-influenced paths, but the dependency range still permits an unsafe version.

Static analysis

No suspicious patterns detected.