Back to skill

Security audit

YOUKU Video Search API

Security checks for vulnerabilities and agentic risk

Overview

This is a focused YOUKU search API wrapper, but it handles the required JustOneAPI token in ways that can expose it through command lines or URL logs.

Use this only with a limited-scope JustOneAPI token and be aware that the token may appear in process metadata and URL logs. Prefer a rotated, low-quota token and avoid running it in environments that record command arguments or full request URLs.

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 (2)

T09 · Insecure Skill Coding Practices

Warning
Location
bin/run.mjs:228
Finding

API Credential Transmitted in the URL Query String

Content
View full analysis
parameter.name === "token"); if (!tokenParam || params.token !== undefined) { return; } if (!cliToken) { fail("--token is required for this operation.", { operationId: operation.operationId, }); } params.token = cliToken; } ``` ```js function applyQueryParams(operation, params, url) { for (const parameter of operation.parameters.filter((item) => item.location === "query")) { const value = params[parameter.name]; if (value === undefined) { continue; } appendValue(url.searchParams, parameter.name, value); } } ``` The resulting URL contains the credential in a form equivalent to: ```text https://api.justoneapi.com/api/youku/search-video/v1?token=SECRET&keyword=... ``` ### Technical Analysis The Skill must authenticate to the declared JustOneAPI endpoint, so transmitting a credential to that service is functionally necessary. However, placing the credential in the URL is not the minimum safe disclosure mechanism. HTTPS protects the URL while it is in transit, but it does not prevent the complete URL from being recorded at either endpoint or by infrastructure that terminates TLS. Query strings are commonly retained by: - API gateway and reverse-proxy access logs - Server request logs - Application performance monitoring and distributed tracing ...[truncated 1693 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:42
Finding

API Credential Exposed Through Process Command-Line Arguments

Content
View full analysis
"}' ``` The argument parser accepts and retains the expanded value: ```js function parseArgs(argv) { const parsed = { operation: null, paramsJson: "{}", token: null }; for (let index = 0; index < argv.length; index += 1) { const flag = argv[index]; const value = argv[index + 1]; if (flag === "--operation") { parsed.operation = value; index += 1; continue; } if (flag === "--params-json") { parsed.paramsJson = value; index += 1; continue; } if (flag === "--token") { parsed.token = value; index += 1; continue; } fail(`Unknown argument "${flag}".`); } return parsed; } ``` The captured value is subsequently used as the API token: ```js function injectToken(operation, params, cliToken) { const tokenParam = operation.parameters.find((parameter) => parameter.name === "token"); if (!tokenParam || params.token !== undefined) { return; } if (!cliToken) { fail("--token is required for this operation.", { operationId: operation.operationId, }); } params.token = cliToken; } ``` ### Technical Analysis Although the token originates in `JUST_ONE_API_TOKEN`, the documented shell command expands it before Node starts. The resulting secret becomes part of the process argument vector. Depending on operating-system access controls and deployment configuration, command-line arguments may be visible through: - Process inspection utilities - `/proc` process metadata on Linux systems - Container or hos ...[truncated 1886 chars]
Remediation
View remediation
"}' ``` 2. Read the token directly from the declared environment variable: ```js const token = process.env.JUST_ONE_API_TOKEN; if (!token) { fail("JUST_ONE_API_TOKEN is required.", { operationId: operation.operationId, }); } injectToken(operation, params, token); ``` 3. Remove or deprecate command-line token parsing so callers cannot accidentally expose credentials through `argv`. 4. If environment variables are not acceptable for a deployment, obtain the credential from a restricted secret manager, protected file descriptor, or standard input rather than command-line arguments. 5. Ensure telemetry and process-monitoring systems do not retain historic commands containing `--token`. 6. Rotate credentials that may have been exposed through process records, shell wrappers, orchestration logs, or execution telemetry. 7. Combine this change with header-based API authentication so the token is exposed through neither the process command line nor the request URL. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (7)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The skill requires the API token to be sent as a URL query parameter, which is less secure than using an Authorization header. Query strings are commonly exposed in logs, browser history, proxy caches, monitoring systems, and error messages, so the credential may be disclosed beyond the intended recipient.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

This code constructs a request to https://api.justoneapi.com and sends query parameters including the search keyword and token. For code files, outbound network transmission of user or system data should have some disclosure such as a prompt, print statement, comment, or documented warning, but none is present here.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

Requiring an authentication token in the query string is risky because query parameters are commonly logged by clients, proxies, gateways, browser history, and monitoring systems even when HTTPS is used. In this skill, the token is a required credential for a third-party API call, so accidental disclosure could let others reuse the credential to access or abuse the external service.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The operation requires a token in the query string, which is commonly exposed in logs, browser history, intermediary proxies, analytics systems, and referrer data. Documenting and encouraging credential transmission via query parameters increases the chance of accidental secret disclosure and reuse beyond the intended recipient.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

This manifest file describes the skill generically as calling a video-search endpoint with a keyword, but it does not define any explicit trigger phrases, scope limits, or exclusion conditions. In a manifest context, that lack of specificity can make invocation criteria ambiguous and increase the chance of unintended activation for broad 'search video' requests.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
83% confidence
Finding

This markdown file describes the skill's capability and purpose in broad terms such as keyword-based discovery, monitoring topics, and market research, but does not specify any concrete trigger phrases, boundaries, or negative examples. In a markdown skill description, that lack of specificity can contribute to unintended invocation because the activation context is unclear.

Content

No source excerpt is available for this finding.