Back to skill

Security audit

Full contact data validation eliminates inaccurate lead information for global B2B prospecting. Run multi-dimensional phone checks to distinguish valid/invalidnumbers, landlines, mobile lines and WhatsApp registered accounts. Complete email authentication to flag active and dormant mailboxes, alongside domainvalidation to confirm functional or defunct business websites. Streamline email validation, phone validation and domain verification workflows for sales teams,recruiters and export businesses. Cut email bounce rates drastically and boost efficiency for B2B cold outreach and global prospect search. Execute professionalCRM data cleansing, candidate screening and supplier lead validation via all-in-one verification features. Perfect for bulk export email pre-sending datacleaning, talent recruitment screening and overseas buyer identity verification.

Security checks for vulnerabilities and agentic risk

Overview

The skill is a disclosed paid contact-validation API wrapper, with some security hygiene issues users should understand before installing.

Install only if you are comfortable sending phone numbers, emails, and domains to UpKuaJing for paid validation. Protect ~/.upkuajing/.env as a secret file, review charges before confirming paid calls or top-ups, and avoid including unnecessary personal or customer data in optional error reports.

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

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/auth.py:60
Finding
API Key Stored Without Explicitly Restrictive File Permissions<![CDATA[ ## Vulnerability Details **File Location**: `scripts/auth.py:60-73` **Vulnerability Type**: Plaintext credential file with inherited permissions **Risk Level**: Medium ### Vulnerable Code ```python UPKUAJING_DIR.mkdir(parents=True, exist_ok=True) with open(env_file, 'w', encoding='utf-8') as f: f.write(f"{API_KEY_ENV}={api_key}\n") ``` ### Technical Analysis The Skill stores a bearer API key in `~/.upkuajing/.env`. Reading this dedicated credential file is necessary for the declared API functionality and does not, by itself, exceed minimum privilege. However, the file and its parent directory are created without explicit restrictive permissions. The resulting permissions depend on the user's process umask and existing directory permissions. In an environment with a permissive umask or a pre-existing broadly accessible directory, another local account or process may be able to read the API key. The implementation also does not defend against the credential path being a symbolic link. If an attacker can control the `~/.upkuajing` directory or `.env` entry, opening the path with truncation could overwrite a file accessible to the victim account. ### Attack Path 1. A victim runs `python scripts/auth.py --new_key`. 2. The Skill requests a new API key from the UpKuaJing service. 3. The returned bearer key is written to `~/.upkuajing/.env` using permissions inherited from the runtime environment. 4. A local attacker with access allowed by those permissions reads the file. 5. The attacker uses the bearer key against the UpKuaJing API. 6. The attacker may consume the victim's API balance, retrieve associated account information, or create a payment-order URL. A symlink-based path is also possible if an attacker already has sufficient local access to manipulate the credential directory before the command runs. ### Impact Assessment Successful exploitation discloses the UpKuaJing bearer credential. The attacker obtains the same API privileges as ...[truncated 242 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Create the credential directory with owner-only permissions: ```python UPKUAJING_DIR.mkdir(mode=0o700, parents=True, exist_ok=True) os.chmod(UPKUAJING_DIR, 0o700) ``` 2. Create the credential file atomically with mode `0600`: ```python flags = os.O_WRONLY | os.O_CREAT | os.O_TRUNC if hasattr(os, "O_NOFOLLOW"): flags |= os.O_NOFOLLOW fd = os.open(env_file, flags, 0o600) with os.fdopen(fd, "w", encoding="utf-8") as f: f.write(f"{API_KEY_ENV}={api_key}\n") ``` 3. Reject symbolic links and verify that the resolved file remains inside the expected directory. 4. Verify and repair permissions on an existing credential file before reading it. 5. Prefer an operating-system credential store or secret manager where available. 6. Avoid displaying any portion of an existing key in error messages, even though the current implementation only displays a prefix. ]]>

T08 · Insecure Dependencies

Note
Location
requirements.txt:1
Finding
Unbounded Dependency Version Prevents Reproducible Installation<![CDATA[ ## Vulnerability Details **File Location**: `requirements.txt:1` **Vulnerability Type**: Unpinned third-party dependency **Risk Level**: Low ### Vulnerable Code ```text httpx>=0.23.0 ``` The documented installation command is: ```bash pip install -r requirements.txt ``` ### Technical Analysis The requirement allows any `httpx` version from 0.23.0 onward, including future major or otherwise unreviewed releases. Transitive dependencies are likewise not locked or hash-verified. `httpx` is a legitimate dependency and no typosquatting, dependency confusion, malicious package source, or known malicious version was identified in the reviewed project. The weakness is that installation is not reproducible and may resolve to code that was unavailable when the Skill was audited. Because Python packages and their dependencies execute with the installing user's privileges, a compromised future release or dependency could affect installation or runtime behavior. An incompatible future release could also change TLS, proxy, redirect, or request semantics. ### Attack Path 1. A user follows the Skill documentation and runs `pip install -r requirements.txt`. 2. The package resolver selects the newest release satisfying `httpx>=0.23.0`, along with currently resolved transitive dependencies. 3. If a selected future release or transitive dependency is compromised, its installation or imported runtime code executes with the user's privileges. 4. That code could access files, environment variables, or network resources available to the Python process, including `UPKUAJING_API_KEY`. This path depends on a future upstream or package-index compromise; no current malicious dependency was established by the static audit. ### Impact Assessment The theoretical impact is bounded by the privileges of the user performing installation or running the Skill. A compromised dependency could read credentials, alter API requests, exfiltrate contact data, or execute arbitrary co ...[truncated 145 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Pin `httpx` and all transitive dependencies to reviewed versions. 2. Generate a lock file using a tool such as `pip-tools`, Poetry, or uv. 3. Require package hashes during installation: ```bash pip install --require-hashes -r requirements.txt ``` 4. Review dependency updates before changing the lock file. 5. Use an isolated virtual environment and avoid installing the Skill as an administrator. 6. Add automated vulnerability and provenance scanning for direct and transitive dependencies. ]]>

other

Note
Location
scripts/version_check.py:91
Finding
Automatic Version Check Discloses Skill Metadata and Writes Persistent State Without Documentation<![CDATA[ ## Vulnerability Details **File Location**: `scripts/version_check.py:91-105` **Additional Location**: `scripts/common.py:200` **Vulnerability Type**: Undisclosed telemetry and persistent cache creation **Risk Level**: Low ### Vulnerable Code ```python url = f"{api_base_url}/agent/api/skills/version" headers = {"Content-Type": "application/json"} with httpx.Client(timeout=10.0) as client: response = client.post(url, json={"name": skill_name}, headers=headers) response.raise_for_status() data = response.json() if data.get("code") == 0: return data.get("data") ``` Every API request invokes the version-check workflow: ```python check_and_notify(API_BASE_URL) ``` The result is cached under the user's home directory: ```python VERSION_CACHE_FILE = UPKUAJING_DIR / 'version_cache.json' ``` ### Technical Analysis Before executing the requested API operation, `make_request` automatically calls the version-check function. On the first applicable call each day, the Skill sends a directory-derived Skill name to `https://openapi.upkuajing.com/agent/api/skills/version`. The request does not contain the API key, phone numbers, email addresses, or domains. It nevertheless reveals metadata indicating that a particular Skill installation is in use. The function also creates `~/.upkuajing` and writes `version_cache.json`, producing persistent state outside the project directory. This behavior is ancillary rather than necessary for contact validation and is not disclosed in `SKILL.md`. It does not retrieve or execute remote code: the remote response is only compared as a version string and may cause an upgrade notice to be printed. ### Attack Path 1. A user invokes any validation, authentication, pricing, payment, or reporting operation that uses `make_request`. 2. `make_request` invokes `check_and_notify` before the requested API call. 3. If no check has been recorded for that day, the Skill sends the local directory-derived Skil ...[truncated 676 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Document the automatic version request and cache file in `SKILL.md`. 2. Make version checking opt-in or provide a documented environment variable or command-line option to disable it. 3. Do not run ancillary network calls automatically before every requested operation. 4. Use the declared Skill metadata name rather than deriving the value from the installation directory. 5. Create the cache directory and file with owner-only permissions. 6. Minimize retained cache fields and provide a command to delete cached metadata. 7. Keep update behavior notification-only; never download or execute remote update payloads automatically. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
Findings (49)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
If the skill performs remote version checks, local cache writes, and SKILL.md parsing beyond the advertised validation task, that expands its behavioral scope and creates additional network and filesystem touchpoints not clearly disclosed to users. Hidden update or telemetry mechanisms can be abused or simply violate least-surprise expectations.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding
If the skill performs remote version checks, local cache writes, and SKILL.md parsing beyond the advertised validation task, that expands its behavioral scope and creates additional network and filesystem touchpoints not clearly disclosed to users. Hidden update or telemetry mechanisms can be abused or simply violate least-surprise expectations.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding
If the skill performs remote version checks, local cache writes, and SKILL.md parsing beyond the advertised validation task, that expands its behavioral scope and creates additional network and filesystem touchpoints not clearly disclosed to users. Hidden update or telemetry mechanisms can be abused or simply violate least-surprise expectations.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
If the skill performs remote version checks, local cache writes, and SKILL.md parsing beyond the advertised validation task, that expands its behavioral scope and creates additional network and filesystem touchpoints not clearly disclosed to users. Hidden update or telemetry mechanisms can be abused or simply violate least-surprise expectations.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
If the skill performs remote version checks, local cache writes, and SKILL.md parsing beyond the advertised validation task, that expands its behavioral scope and creates additional network and filesystem touchpoints not clearly disclosed to users. Hidden update or telemetry mechanisms can be abused or simply violate least-surprise expectations.

Credential Access

High
Category
Privilege Escalation
Content
### **API Key Not Set**
First check if the `~/.upkuajing/.env` file has UPKUAJING_API_KEY;
If UPKUAJING_API_KEY is not set, prompt the user to choose:
1. User has one: User provides it (manually add to ~/.upkuajing/.env file)
2. User doesn't have one: Guide user to apply at [UpKuaJing Open Platform](https://developer.upkuajing.com/)
Wait for user selection;
Confidence
91% confidence
Finding
The skill instructs checking and manually populating `~/.upkuajing/.env` with an API key, which involves local credential discovery and storage. Any skill that reads or writes credential files increases the risk of secret exposure, accidental overwrite, insecure file permissions, or exfiltration if paired with network capabilities.

Credential Access

High
Category
Privilege Escalation
Content
"""
    申请新的 API 密钥。
    """
    # 检查是否已存在 .env 文件和 API key
    env_file = UPKUAJING_ENV_FILE

    if env_file.exists():
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
"""
    申请新的 API 密钥。
    """
    # 检查是否已存在 .env 文件和 API key
    env_file = UPKUAJING_ENV_FILE

    if env_file.exists():
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
"""
    申请新的 API 密钥。
    """
    # 检查是否已存在 .env 文件和 API key
    env_file = UPKUAJING_ENV_FILE

    if env_file.exists():
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
"""
    申请新的 API 密钥。
    """
    # 检查是否已存在 .env 文件和 API key
    env_file = UPKUAJING_ENV_FILE

    if env_file.exists():
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
"""
    申请新的 API 密钥。
    """
    # 检查是否已存在 .env 文件和 API key
    env_file = UPKUAJING_ENV_FILE

    if env_file.exists():
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Credential Access

High
Category
Privilege Escalation
Content
"envFilePath": str(env_file)
        }

    # 保存到 .env 文件
    try:
        with open(env_file, 'w', encoding='utf-8') as f:
            f.write(f"{API_KEY_ENV}={api_key}\n")
Confidence
72% confidence
Finding
Writing a newly issued API key into a plaintext .env file under the user's home directory creates a local secret-storage weakness. If filesystem permissions are too broad, backups are exposed, or other local processes can read the file, the key can be stolen and abused to access the associated account or API usage.

Credential Access

High
Category
Privilege Escalation
Content
except IOError as e:
        return {
            "success": False,
            "message": f"API密钥申请成功,但保存到 .env 文件失败:{str(e)}。\n请手动设置环境变量 {API_KEY_ENV}。",
            "envFilePath": str(env_file)
        }
Confidence
67% confidence
Finding
The failure path instructs the user to manually set the API key as an environment variable, which is not inherently unsafe, but together with plaintext-file storage reflects weak secret-handling practices and increases the chance of exposure through shell history, process listings, or misconfigured environments. This is a security hygiene issue rather than direct credential exfiltration.

Context-Inappropriate Capability

High
Confidence
95% confidence
Finding
Creating recharge orders is a payment-related capability unrelated to validating contact information, and exposing it through this skill can trigger financial workflows users do not expect. In a skill advertised for data cleansing, hidden or loosely justified payment actions are especially risky because they can be abused to initiate unauthorized billing steps or social-engineer users into completing payments.

Credential Access

High
Category
Privilege Escalation
Content
API_BASE_URL = "https://openapi.upkuajing.com"
API_KEY_ENV = "UPKUAJING_API_KEY"
UPKUAJING_DIR = Path.home() / '.upkuajing'
UPKUAJING_ENV_FILE = UPKUAJING_DIR / '.env'
UPKUAJING_LOGS_DIR = UPKUAJING_DIR / 'logs'

# 日志开关
Confidence
60% confidence
Finding
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Lp3

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding
The skill declares no explicit tool scope even though its documented behavior requires environment access, filesystem reads/writes, and network/API calls. That creates an overbroad, under-specified trust boundary: users and hosting platforms cannot easily constrain what the skill may access, increasing the chance of unintended credential, file, or network exposure.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The description embeds activation phrases such as "email validation," "domain verification," and especially "CRM data cleansing," which are broad capability descriptions rather than narrowly scoped invocation triggers. The file does not provide exclusion conditions or negative examples, so these phrases could cause unintended invocation for ordinary requests about general data cleanup or verification.

Context-Inappropriate Capability

Medium
Confidence
93% confidence
Finding
Including top-up order creation and payment guidance inside a contact-validation skill introduces billing functionality outside the core purpose. This increases phishing-like risk and the chance that users are steered into financial actions from a workflow they expected to be purely technical validation.

Natural-Language Policy Violations

Medium
Confidence
93% confidence
Finding
This markdown file presents all user-facing documentation exclusively in Chinese, and it does not indicate that the skill is region-specific or provide any opt-in or alternative language. Under the policy, forcing a specific language without user choice or justification is a natural-language policy violation.

Missing User Warnings

Medium
Confidence
92% confidence
Finding
The document instructs agents to report exceptions by sending request parameters, response data, and error context to a remote API. Even though it mentions automatic masking of sensitive fields, it does not define what is masked, does not require minimization, and does not warn operators that contact data, tokens, stack traces, or user-provided content could be transmitted off-path during failures. In a contact-validation skill, failed requests may contain emails, phone numbers, WhatsApp-related data, and CRM records, making unintended disclosure more likely.

Description-Behavior Mismatch

Medium
Confidence
97% confidence
Finding
This file implements account provisioning, account information lookup, recharge-order creation, and pricing queries, which materially exceed the declared contact-validation behavior of the skill. Such scope expansion increases the attack surface and can enable unintended account or billing interactions through a skill that users would not reasonably expect to manage platform authentication and payments.

Natural-Language Policy Violations

Medium
Confidence
92% confidence
Finding
The module title, descriptions, and all user-facing CLI help/messages are written only in Chinese, which imposes a specific language on users. The file does not offer a language choice or explain that the skill is intended only for a Chinese-speaking or region-specific audience.

Unsafe Defaults

Medium
Category
Tool Misuse
Content
pass  # 如果读取失败,继续执行

    # 不需要认证申请新密钥
    response = make_request('/agent/auth/create', {}, require_auth=False)

    # 检查是否申请成功
    if response.get('code') != 0:
Confidence
75% confidence
Finding
Tool defaults are unsafe or overly permissive (e.g. disabled TLS verification, no authentication, world-writable permissions). Unsafe defaults widen the attack surface.

Unsafe Defaults

Medium
Category
Tool Misuse
Content
pass  # 如果读取失败,继续执行

    # 不需要认证申请新密钥
    response = make_request('/agent/auth/create', {}, require_auth=False)

    # 检查是否申请成功
    if response.get('code') != 0:
Confidence
80% confidence
Finding
Tool defaults are unsafe or overly permissive (e.g. disabled TLS verification, no authentication, world-writable permissions). Unsafe defaults widen the attack surface.

Context-Inappropriate Capability

Medium
Confidence
91% confidence
Finding
Account balance and pricing retrieval expose business-account information beyond the core validation use case and can leak operational or financial metadata. While not as severe as direct payment initiation, these capabilities expand access to sensitive account details and normalize account-management behavior in a skill whose stated purpose is contact verification.

Static analysis

Detected: suspicious.exposed_secret_literal

File appears to expose a hardcoded API secret or token.

Critical
Code
suspicious.exposed_secret_literal
Location
scripts/common.py:196

File appears to expose a hardcoded API secret or token.

Critical
Code
suspicious.exposed_secret_literal
Location
SKILL.md:95