Back to skill

Security audit

sk-doubao-seedream

Security checks for vulnerabilities and agentic risk

Overview

The skill appears to be a legitimate Volcengine image-generation helper, but it handles API keys in ways users should review before installing.

Review before installing if you would use a real Volcengine API key. Prefer `VOLCENGINE_API_KEY` or session-only entry, avoid saving the key in `config.json`, do not use the config display option with a stored key, and avoid submitting sensitive prompts or private images unless third-party processing by Volcengine is acceptable.

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/generate.py:84
Finding

API Key Persisted in Plaintext Configuration

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/config.py:19
Finding

Configuration Utility Can Print and Persist the Complete API Key

Content
View full analysis
Remediation
View remediation

T08 · Insecure Dependencies

Note
Location
README.md:22
Finding

Mutable Latest Package Is Downloaded and Executed During Installation

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (15)

Tainted flow: 'req' from os.environ.get (line 251, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/generate.py (reported line 190)May include surrounding context.

python
"""下载图片到本地"""
    try:
        req = urllib.request.Request(url)
        with urllib.request.urlopen(req, timeout=60) as response:
            img_data = response.read()
            with open(output_path, 'wb') as f:
                f.write(img_data)

Tainted flow: 'req' from os.environ.get (line 251, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/generate.py (reported line 260)May include surrounding context.

python
print(f"正在调用 API...")
        
        with urllib.request.urlopen(req, timeout=120) as response:
            result = json.loads(response.read().decode('utf-8'))
            
            # 处理 Images API 响应

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill description, headings, examples, and configuration guidance are presented entirely in Chinese, which imposes a specific language on users without any opt-in or alternative locale guidance. Under the policy, a skill should not force a language or locale unless it is clearly justified as region-specific or offers user choice.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
95% confidence
Finding

The README instructs users to run npx clawhub@latest install ..., which pulls and executes the latest remote package version at install time rather than a pinned, reviewed release. If the upstream package is compromised or a breaking/malicious version is published, users installing the skill could execute untrusted code on their system.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill clearly integrates with Volcengine Ark image-generation endpoints, but the description does not explicitly warn users that prompts and input images are transmitted to a remote third-party service. This can lead users to disclose sensitive text or images under the false assumption processing is local, creating privacy, confidentiality, and compliance risks.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The script stores the API key in a local JSON file in plaintext without warning the user or applying any protection. If the working directory is shared, backed up, committed to version control, or readable by other local users/processes, the credential can be exposed and abused to access the associated API account.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The code offers to persist the API key in a local config.json file in plaintext, without any warning about credential exposure or file-permission hardening. On multi-user systems, shared workspaces, backups, or accidental commits, this can leak the API key and enable unauthorized API usage.

Content

No source excerpt is available for this finding.

Tainted flow: 'output_path' from input (line 355, user input) → open (file write)

Medium
Category
Data Flow
Confidence
81% confidence
Finding

The script writes downloaded content to a user-supplied output_path without restricting the destination, allowing arbitrary file overwrite within the permissions of the running user. In a local skill context this is not remote code execution, but it can still clobber sensitive files or place files in unintended locations if a caller supplies a dangerous path.

Content

Scanner excerpt · scripts/generate.py (reported line 192)May include surrounding context.

python
req = urllib.request.Request(url)
        with urllib.request.urlopen(req, timeout=60) as response:
            img_data = response.read()
            with open(output_path, 'wb') as f:
                f.write(img_data)
            return img_data
    except Exception as e:

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

In image-to-image mode, the script reads the local image, base64-encodes it, and includes it in a request to the external Ark API. The code prints that it is calling the API, but it does not explicitly disclose that the user's local image data will be uploaded to a third-party service.

Content

No source excerpt is available for this finding.

Tainted flow: 'output_path' from input (line 355, user input) → open (file write)

Medium
Category
Data Flow
Confidence
84% confidence
Finding

Base64-decoded image data from the remote API is written directly to a caller-controlled output path. This creates the same arbitrary file overwrite risk as other write sites: a local or integrated caller can cause the program to write to unintended filesystem locations.

Content

Scanner excerpt · scripts/generate.py (reported line 278)May include surrounding context.

python
if image_b64:
                        img_data = base64.b64decode(image_b64)
                        if output_path:
                            with open(output_path, 'wb') as f:
                                f.write(img_data)
                        return output_path

Tainted flow: 'output_path' from input (line 355, user input) → open (file write)

Medium
Category
Data Flow
Confidence
84% confidence
Finding

This write path saves image data extracted from chat/completions content to a user-controlled filesystem path, again permitting arbitrary file writes under the current user's privileges. The danger is moderate because exploitation requires local/user control of arguments, but in agent or automation contexts that may be enough to overwrite important files.

Content

Scanner excerpt · scripts/generate.py (reported line 293)May include surrounding context.

python
if match:
                        img_data = base64.b64decode(match.group(1))
                        if output_path:
                            with open(output_path, 'wb') as f:
                                f.write(img_data)
                        return output_path

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

The natural-language instructions throughout the skill are presented exclusively in Chinese, including setup and usage guidance, with no indication that users may choose another language or that the skill is intentionally limited to a Chinese-speaking context. Under the stated policy, forcing a specific language without user opt-in can be a locale-policy issue.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
91% confidence
Finding

All natural-language prompts and descriptions in this script are presented in Chinese, and there is no indication that the user can select another language. This can violate a language/locale policy when a skill imposes a specific language without opt-in.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

The script's user-facing docstring and interactive prompts are written in Chinese throughout, implying a fixed language experience. There is no opt-in, locale selection, or documented justification for restricting the interface to a specific language.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

The docstring states that generate_image uses the /api/v3/images/generations endpoint, which is only true for text-to-image mode. In actual code, when an input image is provided, the function switches to the /chat/completions endpoint for vision-based editing, so the documentation is materially inaccurate about the function's behavior.

Content

No source excerpt is available for this finding.