Back to skill

Security audit

IMDb Extended Details API

Security checks for vulnerabilities and agentic risk

Overview

This skill is a focused IMDb API wrapper, but it handles the API token in ways that can expose it through command arguments and URL query logging.

Review before installing if this token has billing, quota, or account-sensitive access. Prefer running it only in environments where process arguments and full request URLs are not logged, avoid sharing command output or diagnostics, and rotate the JustOneAPI token if it may have been captured in logs.

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
SKILL.md:45
Finding

API Token Exposed Through Command-Line Arguments

Content
View full analysis

Vulnerability Details

File Location: SKILL.md:45; token argument handling in bin/run.mjs:183-196
Vulnerability Type: API credential exposure through process arguments
Risk Level: Medium

The documented invocation explicitly passes the JustOneAPI credential through the --token command-line argument:

bash
node {baseDir}/bin/run.mjs --operation "titleExtendedDetailsQuery" --token "$JUST_ONE_API_TOKEN" --params-json '{"id":"<id>"}'

The helper accepts that argument and places its value in the request parameters:

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

Secrets supplied as command-line arguments can be exposed through process metadata. Depending on the operating system and deployment environment, command arguments may be available to other local users, process-monitoring agents, container administrators, job runners, shell auditing facilities, or diagnostic tooling.

Although shell expansion of "$JUST_ONE_API_TOKEN" prevents the value from being written literally into the shell command, the expanded secret is still delivered to Node.js as an argument. Authentication is necessary for the Skill's declared functionality, but exposing the credential through argv is not the minimum safe privilege or disclosure required.

Attack Path

  1. A user or agent follows the documented command and invokes the helper with --token "$JUST_ONE_API_TOKEN".
  2. The shell expands the environment variable and places the credential in the process argument vector.
  3. A local user, process-monitoring service, container administrator, or audit system records or reads the command line while the ...[truncated 757 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove --token from the documented command and command-line parser.
  2. Read the credential directly from process.env.JUST_ONE_API_TOKEN inside the Node.js process:
    js
    const token = process.env.JUST_ONE_API_TOKEN;
    if (!token) {
      fail("JUST_ONE_API_TOKEN is required.");
    }
    
  3. Prefer a secret manager or protected environment-variable injection mechanism in CI, container, and production environments.
  4. Never include the token in process titles, command diagnostics, screenshots, telemetry, or error messages.
  5. Document the required environment variable without showing users how to place its expanded value in argv.
  6. Rotate any token that may already have been captured by process-monitoring or command-auditing systems.

T09 · Insecure Skill Coding Practices

Warning
Location
bin/run.mjs:230
Finding

API Token Transmitted in the URL Query String

Content
View full analysis

Vulnerability Details

File Location: bin/run.mjs:27-35,95-110,230-240; corresponding API definition in generated/operations.json:15-23 and documentation in generated/operations.md:17
Vulnerability Type: Sensitive credential placed in a URL query parameter
Risk Level: Medium

The operation manifest defines the authentication token as a required query parameter:

js
{
  "defaultValue": null,
  "description": "User's authentication token.",
  "enumValues": [],
  "location": "query",
  "name": "token",
  "required": true,
  "schemaType": "string"
}

The helper builds the endpoint URL and appends all parameters whose location is query:

js
const baseUrl = manifest.baseUrl;
const url = new URL(operation.path, ensureBaseUrl(baseUrl));
applyPathParams(operation, params, url);
applyQueryParams(operation, params, url);

const requestInit = {
  headers: {
    "accept": "application/json",
  },
  method: operation.method,
};
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 request has the following sensitive form:

text
https://api.justoneapi.com/api/imdb/title-extended-details-query/v1?token=SECRET&id=tt...

Technical Analysis

URLs are commonly recorded by reverse proxies, API gateways, CDN infrastructure, HTTP access logs, observability platforms, network debugging tools, and server-side analytics. Placing an authentication token in the query string therefore increases its exposure compared with using a protected authentication header.

HTTPS encrypts the request in transit and prevents ordinary network observers from reading the URL path and query. It does not prevent the client, destination server, TLS-terminating proxy, API gateway, or ...[truncated 1604 chars]

Remediation
View remediation

Remediation Suggestions

  1. Change the API authentication contract to use an HTTP authentication header, preferably:
    js
    requestInit.headers.authorization = `Bearer ${token}`;
    
    Use the exact authentication scheme officially supported by JustOneAPI.
  2. Remove token from query-parameter processing and keep it separate from ordinary endpoint parameters.
  3. Update the source OpenAPI security scheme so authentication is represented through securitySchemes, rather than as a query parameter.
  4. Regenerate generated/operations.json and generated/operations.md after correcting the API definition.
  5. Read the token from JUST_ONE_API_TOKEN or a secret manager rather than accepting it in --params-json or --token.
  6. Add explicit URL redaction before any future request logging or error reporting.
  7. Configure gateways, proxies, and observability systems to redact legacy token query parameters.
  8. If the service cannot support header-based authentication, use strict query-value redaction throughout the request path, minimize URL retention, restrict log access, and rotate tokens regularly. This only mitigates the risk and does not eliminate it.
  9. Rotate credentials that may have appeared in existing URL or access logs.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (3)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
89% confidence
Finding

The skill invokes a network-capable helper (node .../bin/run.mjs) to call an external API, but it does not declare an explicit tool scope such as permissions or allowed-tools. This creates a governance gap: platforms or reviewers cannot easily restrict or reason about the skill's external connectivity, which can enable unintended outbound requests or make future malicious changes harder to detect.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The API requires an authentication token to be sent in the URL query string, which is commonly logged by client libraries, reverse proxies, browsers, monitoring systems, and server access logs. Even though the endpoint uses HTTPS, query parameters are still more likely to be exposed than headers, making accidental credential leakage a realistic risk.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

The operation documentation instructs users to pass an authentication token as a query parameter but provides no warning about safe handling of that credential. Query-string tokens are prone to exposure through logs, browser history, analytics, intermediary systems, and referrer leakage, so documenting them without caution increases the chance of credential disclosure.

Content

No source excerpt is available for this finding.