Back to skill

Security audit

Cake Decor Video

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly matches its WeryAI cake-video purpose, but it can send the WeryAI API key to arbitrary environment-configured API hosts, so it needs review before install.

Install only if you trust the publisher and can control the runtime environment. Keep WERYAI_BASE_URL and WERYAI_MODELS_BASE_URL unset or pinned to trusted official HTTPS hosts, use a limited or revocable WeryAI API key, and review generated parameters carefully before confirming paid requests, especially the generate_audio value.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/video_gen.js:24
Finding

Unrestricted API Endpoint Overrides Can Exfiltrate the WeryAI API Key

Content
View full analysis
controller.abort(), 30_000); try { const res = await fetch(fullUrl, { method, headers, body: body != null ? JSON.stringify(body) : undefined, signal: controller.signal, }); clearTimeout(timer); let data; try { data = await res.json(); } catch { data = { status: res.status, msg: `Non-JSON response (HTTP ${res.status})` }; } return { httpStatus: res.status, ...data }; } catch (err) { clearTimeout(timer); if (err.name === 'AbortError') { throw new Error(`Request timeout: ${method} ${fullUrl}`); } throw err; } } async function apiRequest(method, path, body, apiKey) { return httpJson(method, BASE_URL + path, body, apiKey); } async function fetchModelsRegistry(apiKey) { return httpJson('GET', MODELS_BASE_URL + MODELS_API_PATH, null, apiKey); } ``` ### Technical Analysis The Skill legitimately requires network access to WeryAI and must transmit `WERYAI_API_KEY` as a bearer token to the official service. However, both credential-bearing destinations can be replaced through `WERYAI_BASE_URL` and `WERYAI_MODELS_BASE_URL`. The script performs no URL-scheme validation, hostname allowlisting, or explicit authorization before attaching the bearer token. Consequently, an arbitrary destinat ...[truncated 2391 chars]
Remediation
View remediation
Vulnerability Patterns
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • 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 (12)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The declared purpose frames the skill as a narrowly scoped cake-decorating video generator, but the documented behavior indicates broader video generation, image-to-video flows, model querying, and task/job management. This mismatch is dangerous because users, reviewers, or policy systems may approve the skill under a benign niche label while it actually supports more general external-content submission and remote task orchestration than advertised.

Content

No source excerpt is available for this finding.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
**Dependencies**: `scripts/video_gen.js` in this directory + `WERYAI_API_KEY` + Node.js 18+. No dependency on other Cursor skills.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
**Dependencies**: `scripts/video_gen.js` in this directory + `WERYAI_API_KEY` + Node.js 18+. No dependency on other Cursor skills.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
**Dependencies**: `scripts/video_gen.js` in this directory + `WERYAI_API_KEY` + Node.js 18+. No dependency on other Cursor skills.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
**Dependencies**: `scripts/video_gen.js` in this directory + `WERYAI_API_KEY` + Node.js 18+. No dependency on other Cursor skills.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
**Dependencies**: `scripts/video_gen.js` in this directory + `WERYAI_API_KEY` + Node.js 18+. No dependency on other Cursor skills.

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- Does not hard-code absolute paths in the skill doc; `{baseDir}` means the skill package root (same level as `SKILL.md`).

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
87% confidence
Finding

The skill declares runtime requirements that imply access to environment secrets and network egress, but it does not explicitly constrain tool scope with permissions or allowed-tools metadata. In agent environments, that ambiguity can cause the skill to be granted broader capabilities than users or reviewers expect, increasing the chance that API keys, prompts, or generated content are sent externally without clear least-privilege boundaries.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
86% confidence
Finding

The description says to use the skill when the user needs a 'cake decorating reel,' 'piping video,' 'satisfying pastry clip,' or asks for common phrases like 'buttercream roses.' These are broad, natural requests that may overlap with ordinary conversation or more general image/video-generation tasks, without clear exclusion criteria for when this skill should or should not activate.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The implicit trigger example is broad natural-language content describing cake decoration without a strong requirement to invoke the skill explicitly or to satisfy narrowly scoped activation criteria. This can cause the agent to trigger the skill on loosely related aesthetic, baking, or video-generation requests, increasing the chance of unintended tool use and surprising behavior.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
76% confidence
Finding

The document states that the example prompts are 'short triggers only,' but it does not define a bounded list of accepted trigger phrases or provide non-trigger examples. This can leave activation scope ambiguous because many listed examples resemble everyday creative requests that could match other skills.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

The confirmation table and parameter configuration state that generate_audio should default to false, but the example submit command uses "generate_audio":true. This is an active documentation-to-invocation contradiction that could cause the skill to submit materially different requests than the user was told to confirm.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.env_credential_access

Environment variable access combined with network send.

Critical
Code
suspicious.env_credential_access
Location
scripts/video_gen.js:23