Back to skill

Security audit

1688 Distribution Knowledge Newton

Security checks for vulnerabilities and agentic risk

Overview

The skill appears to be a legitimate 1688 knowledge-base query tool, but it handles reusable access keys in ways users should review carefully before installing.

Install only if you are comfortable giving this skill a 1688 Access Key and having it stored in OpenClaw configuration. Prefer configuring the AK through a protected secrets mechanism instead of pasting it into chat or a shell command, check file permissions on `~/.openclaw/openclaw.json`, and avoid setting `OPENCLAW_GATEWAY_URL` to any untrusted host.

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

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/capabilities/configure/cmd.py:29
Finding

Access Key Exposure Through Command-Line Arguments, Plaintext Storage, and Diagnostic Output

Content
View full analysis
``` `scripts/capabilities/configure/service.py:75-89` stores the credential in plaintext without enforcing restrictive permissions: ```python config.setdefault("skills", {}) config["skills"].setdefault("entries", {}) config["skills"]["entries"].setdefault(SKILL_NAME, {}) skill_entry = config["skills"]["entries"][SKILL_NAME] # apiKey 作为唯一写入目标,并移除旧格式 env.ALI_1688_AK 避免误导 skill_entry["apiKey"] = api_key if "env" in skill_entry and isinstance(skill_entry["env"], dict): skill_entry["env"].pop("ALI_1688_AK", None) if not skill_entry["env"]: del skill_entry["env"] CONFIG_PATH.parent.mkdir(parents=True, exist_ok=True) with open(CONFIG_PATH, "w", encoding="utf-8") as f: json.dump(config, f, ensure_ascii=False, indent=2) ``` `scripts/_auth.py:199-216` reveals the complete Access Key ID and the first eight characters of the secret when executed directly: ```python # 测试入口 if __name__ == "__main__": # 从环境变量获取 AK 进行测试 import os test_ak = os.environ.get("ALI_1688_AK") if not test_ak: print("❌ 请先设置环境变量 ALI_1688_AK") pri ...[truncated 2923 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Note
Location
SKILL.md:262
Finding

Unpinned Third-Party Dependency Installation

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (27)

Tainted flow: 'gateway_url' from os.environ.get (line 33, credential/environment) → requests.patch (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

The code builds the REST target from OPENCLAW_GATEWAY_URL and then sends the provided API key in a PATCH request, optionally with an authorization bearer token. If an attacker can influence the environment variable, they can redirect secrets to an attacker-controlled host, creating an SSRF-style exfiltration path for credentials and configuration data.

Content

Scanner excerpt · scripts/capabilities/configure/service.py (reported line 50)May include surrounding context.

python
headers = {}
        if token:
            headers["Authorization"] = f"Bearer {token}"
        resp = requests.patch(f"{gateway_url}/api/config",
                              headers=headers, json=payload, timeout=5)
        return resp.ok
    except Exception:

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The skill's documented behavior includes writing local configuration, modifying apiKey values, and calling a local gateway config endpoint, which goes well beyond merely querying a knowledge base. That discrepancy is security-relevant because it introduces persistent state changes and credential storage under a misleading description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill's documented behavior includes writing local configuration, modifying apiKey values, and calling a local gateway config endpoint, which goes well beyond merely querying a knowledge base. That discrepancy is security-relevant because it introduces persistent state changes and credential storage under a misleading description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill's documented behavior includes writing local configuration, modifying apiKey values, and calling a local gateway config endpoint, which goes well beyond merely querying a knowledge base. That discrepancy is security-relevant because it introduces persistent state changes and credential storage under a misleading description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill's documented behavior includes writing local configuration, modifying apiKey values, and calling a local gateway config endpoint, which goes well beyond merely querying a knowledge base. That discrepancy is security-relevant because it introduces persistent state changes and credential storage under a misleading description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill's documented behavior includes writing local configuration, modifying apiKey values, and calling a local gateway config endpoint, which goes well beyond merely querying a knowledge base. That discrepancy is security-relevant because it introduces persistent state changes and credential storage under a misleading description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill's documented behavior includes writing local configuration, modifying apiKey values, and calling a local gateway config endpoint, which goes well beyond merely querying a knowledge base. That discrepancy is security-relevant because it introduces persistent state changes and credential storage under a misleading description.

Content

No source excerpt is available for this finding.

Ssd 3

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The skill explicitly instructs extracting the AK from a user's natural-language reply and continuing execution. Collecting and processing secrets in conversational text is dangerous because the credential can be exposed in logs, copied into prompts, retained in transcripts, or mishandled by downstream components.

Content

No source excerpt is available for this finding.

Ssd 3

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The guidance explicitly tells the user to send the AK in plaintext format ('我的AK是 xxxxxx'). In the context of a documentation skill, this is especially dangerous because it normalizes insecure secret sharing and can directly leak account-bound access credentials through chat history or monitoring systems.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

This command implements AK configuration and persistence behavior even though the skill is ներկայացित as a 1688 distribution knowledge-base lookup tool. That mismatch is dangerous because users may invoke a seemingly informational skill and instead be prompted to disclose or store credentials, creating a strong opportunity for credential collection under false pretenses.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The code checks for existing AK configuration, accepts a new AK from the command line, validates it, and persists it via a gateway or fallback file. For a knowledge-query skill, this credential inspection and storage capability is unnecessary and expands the attack surface for credential harvesting, unintended persistence, and later misuse of the stored secret.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

Line L141 states that all prompt/output information must use Chinese, which imposes a language policy on users without offering a choice. This matches the policy-violation category for forcing a specific language or locale absent opt-in or documented justification.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
77% confidence
Finding

The skill declares executable capabilities involving environment access, file operations, and network use, but does not declare a tool scope such as permissions or allowed-tools. This weakens least-privilege controls and makes it harder for reviewers or the runtime to constrain what the skill may access, especially because the skill also handles credentials and local configuration.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The instructions require obtaining and configuring a user's AK credential even though the skill is described as a knowledge-query tool. This broadens the trust boundary unnecessarily and creates a pathway for secret collection and storage that users may not anticipate from the advertised functionality.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill asks the user to provide an AK and configure it without any explicit warning about sensitivity, storage, or privacy implications. This increases the risk of accidental credential disclosure, especially in chat logs, transcripts, or shared operator environments.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The file states that all outputs, prompts, and messages must use Chinese, which imposes a fixed language policy on all interactions. This is a natural-language policy violation unless the skill explicitly offers user opt-in or documents a justified region-specific constraint.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This Python file contains natural-language documentation and console output entirely in Chinese, including the module docstring and test messages. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale restriction is explicitly justified, 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
93% confidence
Finding

The file contains natural-language documentation, logging, and error messages in Chinese throughout, which effectively forces a specific language for operators or users interacting with this skill. The policy allows locale constraints only when user choice or clear justification is provided, neither of which appears in this file.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

This code file reads https_proxy from /etc/environment and later uses it for outbound HTTP requests, which can affect where user or system data is transmitted. Although there is an internal logger message when a proxy is used, there is no docstring, comment, or broader user-facing warning explaining that requests may be routed through a proxy.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

This Python file contains natural-language comments and user-facing configuration values entirely in Chinese, including the allowed channel and business names. Because the skill does not indicate any user opt-in, alternative locale support, or region-specific justification, it appears to impose a specific language/locale by default.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The function sends the user-supplied query along with a persistent user identifier to a remote API without any notice, consent flow, minimization, or indication of how the data will be handled. In a knowledge-query skill, users may include operational details or account-related information in natural-language questions, so silent transmission creates a privacy and data-governance risk even if the endpoint is expected.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The command writes the provided AK through a gateway or fallback file path without presenting an explicit warning before storage occurs. This can mislead users into supplying a secret without understanding that it will be persisted beyond the current session, increasing the risk of accidental disclosure or retention in insecure locations.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

This code persists a sensitive credential by writing apiKey into openclaw.json, but there is no confirmation prompt, logging, or explanatory warning in comments/docstrings about the sensitivity of storing the key locally. For safety-critical credential handling, the user should be clearly informed that the key will be saved on disk.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

Lines L049-L057 state that the user's original question must be passed verbatim as the query except for a narrow retry case. But the example at L092-L097 shows a user asking "抖音用自动分销怎么发货" while the actual call uses query="发货", which directly contradicts the stated rule rather than merely omitting detail.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
83% confidence
Finding

The module docstring and inline comments use Chinese exclusively, which constitutes a natural-language locale choice embedded in the skill file. The provided content does not indicate that users may choose another language or that the locale restriction is justified as region-specific.

Content

No source excerpt is available for this finding.