Back to skill

Security audit

Image Compressor

Security checks for vulnerabilities and agentic risk

Overview

This image-compression skill looks like a small demo, but it exposes a credential-like API key and under-specifies paid or external processing.

Review before installing. The publisher should remove and rotate the exposed key, replace it with a nonfunctional placeholder, clearly disclose whether image URLs or files leave the local environment, and add explicit confirmation for paid or external processing. Treat this as a demo unless a real, scoped compression and billing workflow is provided.

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

Plaintext API Credential Exposed in Skill Documentation

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, line 38
Vulnerability Type: Hardcoded secret / plaintext credential exposure
Risk Level: High

Vulnerable Code

markdown
- API Key: sk_93c5ff38cc3e6112623d361fffcc5d1eb1b5844eac9c40043b57c0e08f91430e

Technical Analysis

A secret-shaped API key is embedded directly in the Skill documentation. Any person, process, or agent that can read the project can recover the credential without authentication. Documentation files are commonly committed to source control, distributed with packaged Skills, included in archives, and loaded into agent contexts, significantly increasing the exposure surface.

Static review cannot establish whether the key is currently active or identify its provider and permissions. Nevertheless, storing a credential-like value in plaintext violates secure secret-management practices and must be treated as a credential compromise.

Attack Path

  1. An attacker obtains read access to the repository, distributed Skill package, build artifact, agent context, or source-control history.
  2. The attacker opens SKILL.md and copies the plaintext API key from line 38.
  3. The attacker identifies or already knows the service associated with the key.
  4. If the credential remains valid, the attacker submits authenticated requests using it.
  5. The attacker consumes the account's quota or paid resources within the permissions and limits assigned to the credential.

Impact Assessment

If valid, the exposed key may permit unauthorized access to its associated API. The exact privileges cannot be determined from the audited files and are bounded by the credential's server-side permissions. Potential consequences include unauthorized API operations, quota exhaustion, billing charges, service disruption, and access to data available to that credential.

This finding does not demonstrate host-system privilege escalation, persistence, or arbitrar ...[truncated 17 chars]

Remediation
View remediation

Remediation Suggestions

  1. Revoke the exposed credential and issue a replacement; deletion from the current file alone is insufficient.
  2. Remove the value from the repository and, where feasible, purge it from source-control history and previously distributed artifacts.
  3. Store the replacement in a managed secret store or runtime environment variable rather than source code or documentation.
  4. Replace the documented value with a clearly nonfunctional placeholder, such as YOUR_API_KEY.
  5. Grant the replacement credential only the minimum required permissions and apply usage, spending, origin, or network restrictions supported by the provider.
  6. Review provider access and billing logs for unauthorized use and rotate any related credentials if compromise is suspected.
  7. Add automated secret scanning to pre-commit hooks and CI pipelines to prevent recurrence.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (3)

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The skill embeds a live-looking API key directly in the markdown, which exposes a secret to anyone who can view, copy, or reuse the skill. For an image compression skill, publishing a credential is unnecessary and can enable unauthorized API usage, billing abuse, or access to linked backend resources.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill accepts image URLs and appears to send them to an external compression service, but it provides no warning that user-supplied image data or links will leave the local environment. This creates a privacy and consent issue, especially if users provide sensitive or private images and do not realize they are being transmitted to a third party.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger phrase "Reduce image size" is broad and generic enough that it could cause the skill to activate unexpectedly in unrelated conversations about images or file handling. Overbroad invocation increases the chance of unintended external data transmission or accidental paid API calls without clear user intent.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.exposed_secret_literal

File appears to expose a hardcoded API secret or token.

Critical
Code
suspicious.exposed_secret_literal
Location
SKILL.md:38