Back to skill

Security audit

Trading Calendar Talking Clips

Security checks for vulnerabilities and agentic risk

Overview

This is a real Beatra media-generation skill, but it gives itself broad account access and silently replaces its own installed code by default.

Review before installing. This skill appears intended for Beatra calendar talking-video generation, not theft or destruction, but installing it means allowing a local Python client to store a reusable Beatra token, upload approved local media files, spend Beatra credits, call remote MCP tools, send limited installation metadata, and silently update its own package files unless auto-updates are turned off.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T05 · Unauthorized Access and Privilege Escalation

Warning
Location
scripts/authorize.py:29
Finding
Overprivileged Device Token Grants Capabilities Unrelated to the Skill<![CDATA[ ## Vulnerability Details **File Location**: `scripts/authorize.py:29-33` **Vulnerability Type**: Excessive OAuth scope and violation of least privilege **Risk Level**: Medium ### Vulnerable Code ```python SCOPE = ( "mcp:tools artifacts:write images:generate videos:generate music:generate " "speech:generate voices:read voices:write wallet:spend tasks:read artifacts:read tasks:cancel" ) ``` The authorization process also collects an Agent-platform identifier and local hostname: ```python def detect_host_platform(explicit: str | None = None) -> str: """The agent environment this process runs inside (docs/device-model.md). Order: explicit agent self-report > environment signatures > unknown. Detection reads the process environment only — nothing else runs, nothing reaches the network. """ if explicit: candidate = explicit.strip().lower().replace(" ", "-") if _PLATFORM_VALUE.fullmatch(candidate): return candidate env = os.environ if env.get("CLAUDECODE") == "1" or "CLAUDE_CODE_ENTRYPOINT" in env: return "claude-code" if any(key.startswith("CODEX_") for key in env): return "codex" ai_agent = env.get("AI_AGENT", "").lower() matched = re.match(r"([a-z0-9-]+)_", ai_agent) if matched and _PLATFORM_VALUE.fullmatch(matched.group(1)): return matched.group(1) return "unknown" def device_display_name() -> str | None: """A hostname the user will recognise in the console device list.""" try: name = socket.gethostname().strip() except OSError: return None if not name or not name.isprintable(): return None return name[:120] ``` These values are included in the device-authorization request: ```python form: dict[str, str] = { "client_id": CLIENT_ID, "resource": MCP_URL, "scope": SCOPE, "platform": host_platform, "client_name": PACKAGE_DISPLAY_NAME, "external_installation_ref": external_r ...[truncated 2873 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Remove capabilities that are not required by the documented workflow, particularly: - `images:generate` - `music:generate` 2. Issue a package-specific token rather than reusing a broadly scoped credential shared by multiple Skills. 3. Separate read-only, generation, cancellation, and spending permissions so users can authorize only the capabilities they need. 4. Add a local allowlist in `scripts/mcp_client.py` covering only documented Beatra tools. Reject arbitrary tool names before sending a request. 5. Make hostname transmission opt-in and explain it before authorization. 6. Prefer a user-provided device label or random installation identifier over `socket.gethostname()`. 7. Update the privacy and registration documentation to enumerate every transmitted metadata field, its purpose, retention, and disablement mechanism. ]]>

T03 · Remote Payload Retrieval and Execution

Error
Location
scripts/mcp_client.py:969
Finding
Default Silent Self-Updater Retrieves and Replaces Executable Skill Code<![CDATA[ ## Vulnerability Details **File Location**: `scripts/mcp_client.py:969-1018` **Vulnerability Type**: Remote payload retrieval and automatic code replacement **Risk Level**: High ### Vulnerable Code The updater trusts fixed vendor-controlled discovery and CDN locations: ```python PACKAGE_DISCOVERY_URL = "https://beatra.ai/skills/market-calendar-talking/channels/clawhub/install.json" PACKAGE_CDN_BASE_TEMPLATE = "https://cdn.beatra.ai/agent-packages/market-calendar-talking/channels/clawhub/v{version}" ``` Automatic updates default to enabled, including when state is missing or invalid: ```python def _read_update_state(update_home: Path) -> dict[str, Any]: path = update_home / "state.json" try: value = json.loads(path.read_text(encoding="utf-8")) except (OSError, json.JSONDecodeError): return {"schema_version": 1, "auto_update": True} if not isinstance(value, dict) or value.get("schema_version") != 1: return {"schema_version": 1, "auto_update": True} return value ``` Ordinary commands can silently retrieve and install a newer payload: ```python def maybe_auto_update( *, state_dir: Path | None = None, install_root: Path | None = None, get_bytes: GetBytes = _default_get_bytes, now: float | None = None, ) -> bool: """Best-effort silent update. Never block the requested MCP command.""" resolved_state = state_dir or Path.home() / ".beatra" try: resolved_root = (install_root or _current_install_root()).resolve() update_home = _update_home(resolved_state, resolved_root) observed_at = time.time() if now is None else now nonce = _lock_update(update_home, now=observed_at) if nonce is None: return False try: recover_update(state_dir=resolved_state, install_root=resolved_root) state = _read_update_state(update_home) if state.get("auto_update", True) is False: return False ...[truncated 4327 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Disable automatic installation by default. Make update checking read-only unless the user explicitly approves installation. 2. Verify every release using a digital signature checked against an offline-pinned public key embedded in the audited client. 3. Keep checksum verification, but treat checksums only as integrity controls rather than publisher-authentication controls. 4. Use key rotation metadata signed by an already trusted key, with an explicit revocation and recovery procedure. 5. Display the target version, changed files, signer identity, and release digest before replacing executable files. 6. Require renewed confirmation when an update changes: - Python scripts - `SKILL.md` - authentication behavior - endpoints or requested scopes 7. Prefer updates distributed through the hosting platform's reviewed and signed package mechanism rather than a custom in-band self-updater. 8. Fail closed if local update state is corrupt. Do not interpret malformed or unreadable state as consent to enable automatic installation. 9. Preserve the current path, archive-size, ownership, rollback, downgrade, and redirect protections as defense-in-depth. ]]>
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
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (28)

Lp3

Medium
Category
MCP Least Privilege
Confidence
95% confidence
Finding
The skill invokes a bundled Python client, performs file inspection and uploads, polls remote tasks, and documents auto-update behavior, which implies shell, file, network, and likely environment access despite declaring no permissions. This is dangerous because users and host systems are not given an accurate capability boundary, increasing the chance of silent file access, network egress, and system modification under a low-trust description.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding
The advertised function is producing trading-calendar talking clips, but the skill also introduces credentialed authentication flows, persistent token storage, arbitrary MCP tool invocation, local file upload, telemetry/registration, uninstall cleanup, and software update/install behavior. This mismatch is dangerous because users may authorize a seemingly narrow media workflow without realizing it can store credentials, exfiltrate local data, contact external services, and modify the local installation.

Description-Behavior Mismatch

High
Confidence
97% confidence
Finding
The document describes a built-in self-updater that silently checks for and installs newer package versions, which is unrelated to the stated purpose of generating market-calendar talking clips. Even with integrity checks, this creates a supply-chain modification channel and expands the skill's capabilities to arbitrary software replacement on the host, making compromise of the update trust path highly impactful.

Context-Inappropriate Capability

High
Confidence
98% confidence
Finding
The file documents silent network discovery and automatic installation from fixed remote infrastructure before ordinary commands, which is unjustified for a talking-clip generation skill. This gives the package an unnecessary remote code and file modification pathway; if the update endpoint, signing/checksum workflow, or distribution pipeline is compromised, users could receive malicious updates without meaningful awareness.

Description-Behavior Mismatch

High
Confidence
99% confidence
Finding
This file is materially unrelated to the advertised market-calendar clip function and instead documents installing, authenticating, and operating a remote Beatra MCP client. That mismatch is dangerous because it can smuggle in hidden remote-control and account-linking behavior under an innocuous media-generation skill, expanding access far beyond user expectations.

Context-Inappropriate Capability

High
Confidence
98% confidence
Finding
The skill documents persistent credential reuse and broad access to remote MCP tools spanning multiple media and task capabilities, which is not justified by a simple talking-clip generator. If deployed, this creates an overprivileged integration that could be used to invoke unrelated remote operations or retain long-lived access to the user's Beatra account.

Description-Behavior Mismatch

Medium
Confidence
92% confidence
Finding
The documentation describes an automatic external registration call that sends package slug, version, platform, and a stable installation reference to a backend, which is telemetry-like behavior unrelated to generating market-calendar talking clips. Because it happens on first use and is only described as best-effort and non-billable rather than explicitly user-consented, it creates an unnecessary data transmission channel and expands the skill's attack and privacy surface.

Context-Inappropriate Capability

Medium
Confidence
94% confidence
Finding
The documented installation-registration capability is not justified by the skill's stated purpose of creating talking clips from market calendars and stills. Unrelated networked functionality is a supply-chain and privacy concern because users may install a media-processing skill without expecting outbound package registration, host environment reporting, and persistence of installation metadata.

Description-Behavior Mismatch

High
Confidence
99% confidence
Finding
The OAuth scope string grants a much broader set of account capabilities than the skill’s stated purpose of producing trading-calendar talking clips. In particular, the helper asks for unrelated permissions spanning artifacts, music, voices, tasks, and spending, which violates least privilege and would let a compromised or abusive skill act far outside expected user intent.

Context-Inappropriate Capability

Critical
Confidence
94% confidence
Finding
Requesting tasks:read and tasks:cancel is broader than the manifest justifies and could expose or interfere with unrelated user jobs. While less severe than spending permissions, this still grants the skill visibility into and control over account activity outside the advertised calendar-video workflow.

Context-Inappropriate Capability

High
Confidence
94% confidence
Finding
Requesting tasks:read and tasks:cancel is broader than the manifest justifies and could expose or interfere with unrelated user jobs. While less severe than spending permissions, this still grants the skill visibility into and control over account activity outside the advertised calendar-video workflow.

Context-Inappropriate Capability

High
Confidence
94% confidence
Finding
Requesting tasks:read and tasks:cancel is broader than the manifest justifies and could expose or interfere with unrelated user jobs. While less severe than spending permissions, this still grants the skill visibility into and control over account activity outside the advertised calendar-video workflow.

Context-Inappropriate Capability

Medium
Confidence
94% confidence
Finding
Requesting tasks:read and tasks:cancel is broader than the manifest justifies and could expose or interfere with unrelated user jobs. While less severe than spending permissions, this still grants the skill visibility into and control over account activity outside the advertised calendar-video workflow.

Description-Behavior Mismatch

Medium
Confidence
85% confidence
Finding
The client includes extensive self-update and installation-management behavior unrelated to the stated purpose of generating trading-calendar talking clips. Even though the update path has multiple integrity checks, it materially expands the trust boundary and gives the skill the ability to replace its own code and modify local installation state, which is dangerous for a narrowly scoped media skill.

Description-Behavior Mismatch

Medium
Confidence
88% confidence
Finding
The client records installation telemetry and a local skill inventory despite the manifest describing a narrowly scoped media-creation function. This creates undisclosed persistence and device-level tracking behavior that is outside user expectations and can leak usage metadata about installed skills and host platform over time.

Context-Inappropriate Capability

Medium
Confidence
87% confidence
Finding
The code fingerprints the host environment by inspecting environment variables and persisted host metadata, then attaches the derived platform to outbound tool calls and registration. For a skill whose declared purpose is making talking clips, this is unnecessary device profiling and broadens data collection beyond what is needed for the task.

Description-Behavior Mismatch

High
Confidence
92% confidence
Finding
The uninstall script handles shared device authorization and revocation against a remote Beatra API, which is outside the stated purpose of generating trading-calendar talking clips. Even if framed as lifecycle management, this gives the skill access to cross-skill authentication state and a privileged capability that could affect other installed skills or the user's device authorization.

Context-Inappropriate Capability

Medium
Confidence
89% confidence
Finding
This code reads the shared skills inventory and makes decisions based on other installed skills, which exceeds the least-privilege needs of a media-generation skill. Cross-skill enumeration exposes installation metadata and creates an unnecessary trust boundary violation, allowing one package to inspect or influence shared platform state.

Context-Inappropriate Capability

Medium
Confidence
83% confidence
Finding
The script performs an outbound revocation request during uninstall, using a bearer token from local credentials. While this may be intended cleanup, it creates network-active behavior unrelated to the advertised content-generation function and expands the blast radius if the script or endpoint behavior is abused or replaced.

Missing User Warnings

Medium
Confidence
93% confidence
Finding
The skill states that the bundled client silently installs newer releases automatically without separate confirmation. Even with signature and manifest verification, unprompted code replacement is a system-modifying action that expands the trust boundary after initial approval and can change behavior, permissions, or data handling without informed user consent.

Missing User Warnings

Medium
Confidence
91% confidence
Finding
The markdown states that checks are silent, enabled by default, and may automatically install updates without separate confirmation, but does not present this as a prominent warning about system-modifying behavior. That is dangerous because users invoking a media-generation skill would not reasonably expect background network activity and local file replacement, reducing informed consent and making abuse harder to notice.

Missing User Warnings

Medium
Confidence
90% confidence
Finding
The documentation states that the client automatically performs installation registration on first use, but it does not present this as a clear user warning or consent flow before data leaves the system. Silent outbound transmission of environment and installation metadata is risky because users cannot make an informed decision and may be unaware that using a local creative tool triggers external reporting.

Missing User Warnings

Medium
Confidence
93% confidence
Finding
The skill performs silent automatic self-updates that can replace installed package files during normal operation without an execution-time warning. In the context of a media-generation skill, this is particularly risky because it allows behavior changes and code replacement outside the user's immediate awareness, increasing supply-chain and post-install trust risks.

Credential Access

High
Category
Privilege Escalation
Content
- `~/.beatra/installation.json` contains one stable, non-secret installation
  reference.
- `~/.beatra/credentials.json` contains the single Device Token.

On POSIX systems the directory must be mode `0700` and both files mode `0600`.
On Windows the current user must be the only principal granted access through
Confidence
91% confidence
Finding
This documents storage and use of a persistent Device Token in a local credentials file, which is sensitive credential material. In the context of an unrelated-looking skill, instructing the agent to maintain reusable authentication artifacts increases the risk of credential theft, misuse by other components, or unauthorized continued access if host isolation is weak.

Credential Access

High
Category
Privilege Escalation
Content
4. polls every 5 seconds for up to 15 minutes while the user signs in (or
   creates their account) and selects Allow;
5. atomically saves the returned Device Token to
   `~/.beatra/credentials.json` without printing an HTTP response body;
6. validates the new credential with the same non-billable MCP request and
   prints Ready only after it succeeds.
Confidence
93% confidence
Finding
Automatically saving the returned Device Token to a reusable local file establishes durable account access that can outlive the immediate task. In this skill context, that is especially risky because the advertised functionality does not obviously require broad, persistent MCP authentication, making covert credential persistence more suspicious and potentially exploitable.

Static analysis

No suspicious patterns detected.