Back to skill

Security audit

Compress

Security checks for vulnerabilities and agentic risk

Overview

This skill appears to be a text-compression helper, but it asks for command execution even though its documented function does not need it.

Review this skill carefully before installing. Its text-compression purpose is understandable, but command execution is not needed for that purpose, so users should prefer a version that removes exec and documents the compression, validation, and checksum outputs clearly. Do not use it for medical, legal, financial, or safety-critical text where semantic loss matters.

Vulnerability Patterns
  • 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
  • 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)

T05 · Unauthorized Access and Privilege Escalation

Warning
Location
SKILL.md:14
Finding

Unnecessary Command-Execution Capability Violates Least Privilege

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 14–16
Vulnerability Type: Excessive tool permissions
Risk Level: Medium

yaml
tools:
  - read
  - exec

Technical Analysis

The skill declares access to the exec tool even though its documented purpose is semantic text compression and validation using an agent-provided LLM. The documented workflow contains no operation that legitimately requires executing operating-system commands.

Granting command-execution access violates the principle of least privilege and unnecessarily expands the skill's attack surface. On a platform that grants the tools declared in skill metadata, attacker-controlled text or prompt manipulation could influence the agent into invoking shell commands unrelated to semantic compression.

The project contains no executable scripts or explicit malicious commands. Therefore, this finding concerns the unnecessary capability exposed by the configuration rather than confirmed command execution.

Attack Path

  1. A platform loads SKILL.md and grants the declared exec capability.
  2. An attacker supplies crafted content as text to be compressed or otherwise manipulates the agent's active instructions.
  3. The agent interprets the malicious content as a reason to invoke exec.
  4. A command is executed with the operating-system permissions of the hosting agent process.
  5. Depending on host sandboxing and process privileges, the command could access files, alter local data, invoke installed programs, or communicate with external systems.

This exploitation path is conditional on the hosting platform honoring the declared tool list and failing to sufficiently isolate tool use from untrusted input.

Impact Assessment

Successful exploitation could provide command execution under the privileges of the agent process. The accessible scope may include local files, environment variables, installed appli ...[truncated 344 chars]

Remediation
View remediation

Remediation Suggestions

  1. Remove exec from the declared tool list:

    yaml
    tools:
      - read
    
  2. If all input is supplied directly in the conversation, consider removing read as well and declaring no external tools.

  3. Enforce tool permissions independently at the hosting-platform level rather than relying solely on skill metadata.

  4. Require explicit user approval for any future command execution capability.

  5. If command execution later becomes necessary, use a narrowly scoped allowlist of fixed commands and arguments, reject shell metacharacters, run commands in a restricted sandbox, and prevent access to secrets and unnecessary network resources.

  6. Add security tests confirming that attacker-controlled compression input cannot cause tool invocation.

Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (4)

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The description says to use the skill whenever the user needs 'Compress-related functionality', which is not a specific trigger and lacks clear boundaries for when the skill should or should not activate. This broad phrasing can overlap with many ordinary requests involving summarization or text editing, increasing the risk of unintended invocation.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The documented output schema describes a grading/evaluation report rather than compressed text, checksums, or validation artifacts promised by the skill. This mismatch can cause downstream agents or users to trust incorrect semantics, mishandle outputs, or chain the skill into inappropriate workflows, increasing the chance of silent data corruption or policy bypass through format confusion.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
79% confidence
Finding

The invocation guidance is written as a Chinese-language instruction embedded in an otherwise English description, suggesting a language-specific operating assumption without stating that the user can choose their preferred language. This can create a locale expectation that is not explicitly documented as optional or justified.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
89% confidence
Finding

The input contract only exposes text_content and compression_ratio, but the skill claims support for iterative validation and anchor verification, which would require additional inputs or clearly defined internal behavior. This inconsistency can lead to insecure assumptions about integrity guarantees, with users believing validation occurred when required data was never supplied.

Content

No source excerpt is available for this finding.