Back to skill

Security audit

Yufluent Clawhub Publish Yufluentcn Compliance Guard

Security checks for vulnerabilities and agentic risk

Overview

This skill is a cloud-backed compliance helper, but it gives an environment variable control over where the API token and business data are sent and has a local import-path weakness users should review before installing.

Install only if you trust the Yufluent service and can control the runtime environment. Keep TOKENAPI_BASE_URL unset unless you intentionally use a trusted endpoint, prefer HTTPS, protect TOKENAPI_KEY as a reusable credential, and avoid putting unnecessary secrets or personal data into the free-form context field.

Vulnerability Patterns
  • Tool Hijacking and SpoofingModifies or replaces tools so legitimate-looking calls execute attacker logic
  • 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

Error
Location
scripts/yufluent_api.py:20
Finding

Bearer Token and Sensitive Business Data Can Be Transmitted over an Untrusted Plaintext Endpoint

Content
View full analysis
str: base = (base_url or "").strip().rstrip("/") if not base: base = "http://localhost:8080/v1" if base.endswith("/v1"): return base return f"{base}/v1" ``` ```python def _auth_headers(api_key: str) -> dict[str, str]: return { "Authorization": f"Bearer {api_key}", "Accept": "application/json", } ``` ```python def _post_json( url: str, *, api_key: str, body: dict[str, Any] | None = None, timeout: float, ) -> requests.Response: kwargs: dict[str, Any] = { "headers": _json_headers(api_key) if body is not None else _auth_headers(api_key), "timeout": timeout, } if body is not None: kwargs["json"] = body return requests.post(url, **kwargs) ``` ```python root = base_url or os.getenv("TOKENAPI_BASE_URL", "") url = skill_run_url(root, skill_id) try: resp = _post_json(url, api_key=key, body=payload, timeout=timeout) except requests.RequestException as exc: raise YufluentApiError(f"Request failed: {exc}") from exc ``` The transmitted payload is assembled in `scripts/run.py`: ```python payload: dict = { "message": args.message.strip(), "product": args.product.strip(), "mode": args.mode, "platform": args.platform, "lang": args.lang, } if args.target_market: payload["target_market"] = args.target_market.strip() if args.category: payload["category"] = args.category.strip() if args.material: payload["material"] = args.material.strip() if args.declared_value: payload["declared_value"] = args.declared_value.strip() if args.hs_code: payload["hs_code"] = args.hs_code.strip() if args.origin ...[truncated 2687 chars]
Remediation
View remediation

T07 · Tool Hijacking and Spoofing

Warning
Location
scripts/run.py:9
Finding

External Shared Directory Can Hijack the Bootstrap Module Import

Content
View full analysis
/_shared`, such as through an unsafe shared installation directory, another package, or compromised deployment tooling. 2. The attacker creates `_shared/bootstrap.py` containing malicious top-level Python code. 3. A user starts the ...[truncated 1165 chars]
Remediation
View remediation
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
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
Findings (17)

Tainted flow: 'url' from os.getenv (line 271, credential/environment) → requests.post (network output)

Critical
Category
Data Flow
Confidence
93% confidence
Finding

The client allows the request destination to be derived from TOKENAPI_BASE_URL without validating the scheme, host, or trust boundary, and then sends the Bearer API key and payload to that URL. If an attacker can influence the environment or packaging/runtime configuration, they can redirect requests to an attacker-controlled server and exfiltrate credentials and user-supplied compliance data; the default fallback to plain HTTP localhost also weakens transport assumptions.

Content

Scanner excerpt · scripts/yufluent_api.py (reported line 150)May include surrounding context.

python
}
    if body is not None:
        kwargs["json"] = body
    return requests.post(url, **kwargs)


def _raise_for_status(resp: requests.Response) -> None:

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The second behavior mismatch is more severe: a skill presented as compliance guidance reportedly reads arbitrary local files and encodes local images while containing no actual compliance logic. Arbitrary file reading in a cloud-connected skill can expose sensitive local data to remote services under the cover of a harmless-seeming business workflow.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The second behavior mismatch is more severe: a skill presented as compliance guidance reportedly reads arbitrary local files and encodes local images while containing no actual compliance logic. Arbitrary file reading in a cloud-connected skill can expose sensitive local data to remote services under the cover of a harmless-seeming business workflow.

Content

No source excerpt is available for this finding.

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 28)May include surrounding context.

md
## 快速开始(3 步,60 秒)

1. **注册获取 API 密钥** → https://claw.changzhiai.com/login (新用户即送体验积分,无需绑卡)
2. **设置环境变量**:export TOKENAPI_KEY=*** 或写入 .env 文件
3. **运行**:参照下方 Examples 示例执行 python scripts/run.py ...

> 还没注册?前往 https://claw.changzhiai.com/login 免费获取密钥。

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill name, description, usage examples, and mode explanations are entirely in Chinese, which indicates a fixed language expectation for users. There is no note that Chinese is optional, no multilingual alternative, and no justification that the skill is limited to a Chinese-speaking or region-specific audience.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
82% confidence
Finding

The skill advertises network and environment-variable driven execution via a cloud harness but does not declare an explicit tool scope such as allowed-tools or permissions. That creates an authorization and review gap: operators cannot easily constrain or audit what resources the skill is expected to access, increasing the chance of over-privileged execution or unexpected data exposure.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The trigger phrase "亚马逊新规影响" is broad and could match many general discussions about marketplace policy changes, not just requests to invoke this specific skill. The markdown does not provide exclusion conditions or tighter context boundaries for when this phrase should or should not activate the skill.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger "HS 编码" is too short and generic to serve as a safe activation condition because it can appear in ordinary conversation, documentation, or clarification questions. The file does not define scope limits or negative examples to distinguish casual mention from an actual request to run the skill.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The phrase "CE 认证" is a broad topic label rather than a specific invocation trigger, so it may collide with ordinary discussion, search, or explanatory text. The skill description does not add constraints, trigger syntax, or negative examples to prevent unintended activation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The natural-language strings in the module documentation and function docstrings are written exclusively in Chinese, which signals a fixed language choice for the skill's operator-facing documentation. The provided policy requires flagging language or locale constraints when the skill does not offer a language choice or clearly justify the constraint.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The CLI sets --lang to default to zh, which imposes a specific language/locale unless the user explicitly overrides it. This is a natural-language policy concern because the skill does not prompt for or negotiate language choice before defaulting to Chinese output.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

When the direct skill endpoint fails, the code falls back to a generic /agent/turn orchestration path that can invoke broader agent behavior than a single-purpose compliance skill. Expanding execution through a general agent interface increases the risk of unintended actions, prompt-based behavior drift, and transmission of structured user inputs into a more capable backend than users would reasonably expect.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The natural-language prompt construction hardcodes Chinese instructions such as '请直接执行技能' and the rest of the module's user-facing messages are also exclusively in Chinese. This imposes a specific language/locale without opt-in or explanation, which matches the policy category for language or locale constraint violations.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

This code posts JSON bodies and bearer-token authorization headers to remote endpoints via requests.post, which can send user-supplied payload data and credentials over the network. While the module docstring identifies it as a cloud thin client, there is no explicit user-facing warning, confirmation, or comment near the transmission points explaining that payload contents are sent to a remote service.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The helper exposes a secondary telemetry-like capability to POST agent outcomes to /agent/outcomes, which is outside the narrow user-expected function of a compliance-reference assistant. That creates an additional data egress path for potentially sensitive business inputs, results, or interaction metadata without clear user disclosure or necessity in this skill context.

Content

No source excerpt is available for this finding.

Unpinned Dependencies

Low
Category
Supply Chain
Confidence
93% confidence
Finding

The dependency is specified as requests>=2.31.0, which allows any future release and prevents reproducible installs. This can introduce vulnerable or incompatible versions into deployments over time, and in a security-sensitive compliance assistant that may process external URLs or remote content, dependency drift increases supply-chain risk.

Content

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

text
requests>=2.31.0

Unverifiable Dependency: requests has 16 known advisory(ies) (CVE-2014-1830 (Exposure of Sensitive Information to an Unauthorized Actor in Requests); 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) +13 more), but the manifest does not pin a version, so it is unknown whether the installed release is affected

Low
Category
Supply Chain
Confidence
90% confidence
Finding

Because requests is not pinned, it is not possible to verify whether the installed version is affected by any of the known advisories for that package. In a cloud-backed compliance skill that likely makes outbound HTTP requests, this uncertainty matters more because network-facing libraries are common attack surfaces and may expose credentials, TLS state, or request handling weaknesses if a vulnerable release is installed.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.