Back to skill

Security audit

Plume NoteCard

Security checks for vulnerabilities and agentic risk

Overview

The skill is a real Plume notecard client, but its project-controlled configuration and loose file upload/logging behavior can expose secrets or private content.

Install only if you trust the workspace and the Plume service configuration. Do not run it in untrusted repositories containing .plume-notecard/EXTEND.md, avoid using it with confidential documents or sensitive images, and review or clear the media/action-log directory after use.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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 (4)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/config.py:193
Finding

Project-Controlled API Endpoint Can Exfiltrate Environment Secrets and User Data

Content
View full analysis
Optional[str]: """多源获取 API Key""" # 1. 环境变量 key = os.environ.get("PLUME_API_KEY") if key: return key # 2. EXTEND.md 中指定的环境变量名 config = load_extend_config() api_key_env = config.get("api_key_env") if api_key_env and isinstance(api_key_env, str): key = os.environ.get(api_key_env) if key: return key # 3. OpenClaw 配置文件 env = detect_agent_env() if env["agent"] == "openclaw": openclaw_config = Path.home() / ".openclaw" / "openclaw.json" if openclaw_config.exists(): try: data = json.loads(openclaw_config.read_text(encoding="utf-8")) key = (data.get("env", {}).get("vars", {}).get("PLUME_API_KEY") or data.get("env", {}).get("PLUME_API_KEY")) if key: return key except (json.JSONDecodeError, OSError): pass return None def get_api_base() -> str: """获取 API Base URL""" config = load_extend_config() return config.get("api_base_url") or "https://design.useplume.app" ``` ```python # scripts/plume_api.py:20-31, 128-145 def get_config(): """获取 API Key 和 Base URL(多源)""" api_key = config.get_api_key() if not api_key: print("Error: PLUME_API_KEY must be set in environment.") sys.exit(1) api_base = config.get_api_base() return api_key, api_base def create_task(category: str, content: dict, project_id: str = None, widget_mapping: dict = None, title: str = None) -> dict: """创建 AI 任务""" api_key, api_base = get_config() url = f"{api_base}/api/open/tasks" ...[truncated 2295 chars]
Remediation
View remediation

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/create_notecard.py:135
Finding

Reference-Image Transfer Can Upload Arbitrary Readable Local Files

Content
View full analysis
str: """通过 magic bytes 检测真实 MIME 类型,后缀作为 fallback""" import mimetypes if file_data[:3] == b'\xff\xd8\xff': return "image/jpeg" if file_data[:8] == b'\x89PNG\r\n\x1a\n': return "image/png" if file_data[:4] == b'RIFF' and file_data[8:12] == b'WEBP': return "image/webp" if file_data ...[truncated 3208 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/create_notecard.py:198
Finding

Full User Content and Local Paths Are Logged and Persisted Without Adequate Protection

Content
View full analysis
dict: """提取创建参数快照,用于重试时还原""" params = {} for key in ("article", "style_hint", "aspect_ratio", "locale"): val = getattr(args, key, None) if val is not None: params[key] = val if mode == "reference": for key in ("reference_type", "reference_image_urls", "reference_topic", "reference_article"): val = getattr(args, key, None) if val is not None: params[key] = val if (args.count or 1) >= 2: params["count"] = args.count if args.child_reference_type: params["child_reference_type"] = args.child_reference_type return params ``` ```python # scripts/create_notecard.py:449-462 if task_id: log_entry = { "task_id": task_id, "action": args.action, "last_task_id": args.last_task_id, "mode": mode, "params": _build_params_snapshot(args, mode), } action_log.append_entry(args.channel or "", log_entry) ``` ```python # scripts/create_notecard.py:976-978 try: log(f"=== create_notecard.py {args.command} called, argv={sys.argv[1:]} ===") commands[args.command](args) ``` ```python # scripts/action_log.py:33-61 def _log_path(channel: str) -> Path: media_dir = config.get_media_dir() filename = f"action_log_{channel}.json" if channel else "action_log.json" return media_dir / filename def _write_log(channel: str, log: list[dict]): """写入日志,超出上限时 FIFO 淘汰""" max_size = _get_max_log_size() media_dir = config.get_media_dir() media_dir.mkdir(parents=True, exist_ok=True) if len(log) > max_size: ...[truncated 2120 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/create_notecard.py:529
Finding

Unbounded Image Downloads Can Exhaust Local Storage

Content
View full analysis
bool: """安全下载文件到本地:仅 HTTPS + 限制重定向 + 校验 Content-Type""" if not url.startswith("https://"): log(f"下载拒绝:仅允许 HTTPS URL, url={url[:80]}") return False opener = urllib.request.build_opener( RedirectLimitHandler(MAX_REDIRECTS), urllib.request.HTTPSHandler(context=SSL_CONTEXT), ) req = urllib.request.Request(url, headers={"User-Agent": "Plume-Notecard/1.0"}) try: with opener.open(req, timeout=timeout) as resp: content_type = resp.headers.get("Content-Type", "") if not content_type.startswith(ALLOWED_CONTENT_TYPES): log(f"下载拒绝:非法 Content-Type={content_type}") return False with open(output_path, "wb") as f: while True: chunk = resp.read(1024 * 1024) if not chunk: break f.write(chunk) if os.path.getsize(output_path) == 0: os.remove(output_path) return False return True except Exception as e: log(f"下载失败: {e}") try: if os.path.exists(output_path): os.remove(output_path) except OSError: pass return False ``` ### Technical Analysis The downloader correctly requires an HTTPS URL, limits redirects, and checks that the declared response type starts with `image/`. However, it does not limit `Content-Length` or count the number of bytes received while streaming. A remote server can label an arbitrarily large or effectively endless response as `image/png`. The loop writes data until the server closes the response or an exception occurs. A socket timeout do ...[truncated 1131 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (28)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared description presents a user-facing content generation skill for creating notecards, infographics, and slide decks from text or images. The supplied code does not generate, transform, or process any content or images. Instead, it only checks whether an API key is configured by calling config.get_api_key() and reporting success/failure. This is a materially different primary purpose from the declared behavior. While configuration checking could be a supporting utility within such a skill, this specific code chunk itself does not implement any of the declared notecard-generation capabilities, so the description does not accurately represent what this code chunk actually does.

Content

No source excerpt is available for this finding.

External Script Fetching

High
Category
Supply Chain
Confidence
90% confidence
Finding

Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.

Content

Scanner excerpt · SKILL.md (reported line 31)May include surrounding context.

md
This skill follows these security practices:

- Credential stripping for secrets, API keys, and tokens
- No remote code execution patterns like `curl | bash`
- HTTPS-only downloads with redirect limits (max 5)
- Content-Type validation for downloaded files (image/* only)
- Sanitized logging with no secret leakage

Lp1

High
Category
MCP Least Privilege
Confidence
75% confidence
Finding

The skill uses 'file_read' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

Lp1

High
Category
MCP Least Privilege
Confidence
75% confidence
Finding

The skill uses 'file_write' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

Lp1

High
Category
MCP Least Privilege
Confidence
75% confidence
Finding

The skill uses 'env' capability that is not listed in its permissions. This may indicate deceptive intent or missing permission declarations.

Content

No source excerpt is available for this finding.

Lp1

High
Category
MCP Least Privilege
Confidence
88% confidence
Finding

The script has clear network capabilities: it uploads local files to R2, calls remote task APIs, polls task state, and downloads remote images. If the skill manifest does not explicitly declare network permission, this creates a capability mismatch that can bypass user/admin expectations and weakens sandbox or approval controls around external data transfer.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The activation phrases include broad terms like 'card', 'diagram', and 'image slides', which can cause the skill to trigger in unrelated conversations. In this skill's context, unintended activation is more risky because it can lead the agent to inspect local config state, prompt around API-backed operations, or initiate external-content workflows when the user did not intend to use this service.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The documentation states --locale defaults to zh-CN, which imposes a specific language/locale by default. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the constraint is clearly justified or optional by explicit choice.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The workflow explicitly shows user-uploaded images being transferred to an external service and user-provided article text being sent for processing, but it omits any user-facing disclosure, consent step, or data-handling warning. In a skill designed to process potentially sensitive documents and images, this can cause inadvertent exposure of personal, proprietary, or confidential content to downstream systems.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The history workflows demonstrate retrieving prior task metadata and local file paths, then reusing those artifacts for merge/zip operations, without warning users that prior generated assets may be accessible and reused in later commands. This creates a privacy and cross-session data exposure risk, especially if channel identifiers are guessable, reused, or shared across users or agents.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The module explicitly states it records complete task parameters and results to disk for retries and circuit-breaking, which can capture sensitive user content, images, prompts, or identifiers without any minimization, retention control beyond count-based truncation, or user disclosure in this code path. In a notecard-generation skill that processes long-form text and reference images, this increases privacy risk because the logged payloads may contain confidential documents or proprietary media.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

This code retrieves API keys from environment variables and reads them from the user's OpenClaw configuration file, which is a sensitive credential source. While the functions have internal docstrings, there is no user-facing prompt, warning, or disclosure indicating that credentials will be accessed from the environment or local config.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The script exposes history retrieval and local export/packaging features beyond the described notecard-generation behavior. Extra undeclared capabilities increase attack surface and may enable unintended access to prior task metadata or repackaging of local files in ways users and reviewers did not consent to.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The create payload sets locale to args.locale or "zh-CN", which forces Chinese locale whenever the caller does not explicitly choose one. This is a natural-language policy concern because the skill imposes a specific language/locale by default rather than offering a neutral default or explicit opt-in.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

In deck mode, the script again assigns locale as args.locale or "zh-CN", causing Chinese locale to be applied automatically when no preference is supplied. This enforces a language setting without explicit user choice.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

For batch generation, the script silently falls back to zh-CN when no locale is provided. That behavior can produce output in an unexpected language and violates the requirement to avoid forcing a locale without opt-in.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

For standard single-card creation, the payload uses args.locale or "zh-CN", so the skill selects Chinese output even when the user has not requested it. This is a direct language/locale policy issue under the stated rules.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

PDF merging and ZIP packaging are additional file-processing/export capabilities not reflected in the declared supported actions. Even though they operate on local paths provided to the script, undeclared export features can be abused to transform or bundle files in ways outside the approved skill scope, increasing the risk of data handling surprises.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The code uploads a local image file to a remote API endpoint as soon as upload_image() is called, with no built-in consent, disclosure, or policy check in this module. In the context of a notecard-generation skill that explicitly supports reference images and product images, this creates a real privacy/data-handling risk because sensitive user images could be transmitted off-device or off-platform without an explicit user-facing confirmation step at the point of use.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
93% confidence
Finding

The file states that the agent should automatically choose the template gallery link based on the language currently used in conversation. This imposes a language/locale choice implicitly rather than offering the user a choice or explicit opt-in, which can violate language preference policy expectations.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The documentation includes the Chinese phrase "正在处理" within an otherwise English reference table. This introduces a language-specific presentation requirement without offering a user language choice or documenting a justified locale scope.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

The phrases "判断" in the polling recommendations are Chinese-only terms embedded in otherwise English instructions. Because the file does not state that it is intended for a Chinese-speaking or bilingual audience, this conflicts with the language/locale policy criteria.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
81% confidence
Finding

The natural-language documentation and inline descriptions in this file are exclusively Chinese. Under the policy, forcing a specific language without opt-in or justification can be a locale/language policy violation, especially when no alternative language support is indicated.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The module docstring is entirely in Chinese and provides the skill's behavior description without any opt-in or indication that the tool is region-specific. Under the language/locale policy, forcing a specific language in natural-language content without user choice can be a policy violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

The module docstrings and comments are written exclusively in Chinese, which suggests a language-specific skill presentation without offering users a language or locale choice. Under the policy, forcing a specific language without opt-in can be a natural-language policy violation unless the locale constraint is documented and justified.

Content

No source excerpt is available for this finding.