Back to skill

Security audit

File Converter

Security checks for vulnerabilities and agentic risk

Overview

This appears to be a real file-conversion skill, but it needs Review because it includes under-documented PDF manipulation features and lacks clear safeguards for broad file writes.

Install only if you are comfortable reviewing file outputs carefully. Use a dedicated virtual environment, process only files and folders you explicitly choose, avoid batch runs on important directories, choose separate output folders, and treat CSV files from untrusted sources as potentially able to create active spreadsheet formulas.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (2)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/excel_csv_converter.py:83
Finding

CSV-to-XLSX Formula Injection

Content
View full analysis

Vulnerability Details

File Location: scripts/excel_csv_converter.py, lines 83-90
Vulnerability Type: Untrusted spreadsheet formula injection
Risk Level: Medium

Affected Code:

python
with open(input_file, "r", encoding=encoding, newline="") as f:
    reader = csv.reader(f, delimiter=delimiter)
    
    for row_idx, row in enumerate(reader, 1):
        for col_idx, value in enumerate(row, 1):
            ws.cell(row=row_idx, column=col_idx, value=value)
        row_count += 1

Technical Analysis

Values read from the source CSV are written directly into XLSX cells without distinguishing plain text from formulas. In particular, OpenPyXL interprets strings beginning with = as spreadsheet formulas.

Consequently, an attacker who controls the CSV can cause the generated workbook to contain active formulas rather than inert text. Formula payloads may include deceptive hyperlinks, external workbook references, or functions that cause network interactions when supported and permitted by the spreadsheet client.

Defensive handling should also account for values beginning with +, -, or @, because some spreadsheet applications or subsequent export workflows may interpret these prefixes as formulas.

Attack Path

  1. An attacker creates or modifies a CSV processed by the Skill.

  2. A cell contains a formula-like value, for example:

    csv
    Name,Reference
    Invoice,"=HYPERLINK(""https://attacker.invalid/collect"",""Open invoice"")"
    
  3. The user or Agent invokes the CSV-to-XLSX conversion.

  4. The converter passes the value directly to ws.cell(..., value=value).

  5. OpenPyXL stores the value as a formula in the generated workbook.

  6. A recipient opens the workbook and may be shown an attacker-controlled link or prompt. Depending on the formulas used, the spreadsheet client, and its security settings, external resources may be accessed or sensitive workbook content ...[truncated 737 chars]

Remediation
View remediation

Remediation Suggestions

Sanitize untrusted CSV values before writing them to workbook cells:

  1. Treat imported CSV fields as plain text by default.
  2. Detect values whose first non-whitespace character is =, +, -, or @.
  3. Prefix formula-like values with an apostrophe or explicitly assign the cell's data type as a string.
  4. Provide an explicit opt-in option if trusted users need formulas preserved.
  5. Document that formula preservation must not be enabled for untrusted input.
  6. Add tests covering formula prefixes, leading whitespace, tabs, carriage returns, quoted CSV fields, and alternative encodings.

Example defensive implementation:

python
def neutralize_formula(value):
    if not isinstance(value, str):
        return value

    candidate = value.lstrip()
    if candidate.startswith(("=", "+", "-", "@")):
        return "'" + value
    return value

for row_idx, row in enumerate(reader, 1):
    for col_idx, value in enumerate(row, 1):
        ws.cell(
            row=row_idx,
            column=col_idx,
            value=neutralize_formula(value),
        )

If formulas must never be supported, explicitly create text cells and verify the resulting XLSX does not contain formula records.

T08 · Insecure Dependencies

Note
Location
SKILL.md:48
Finding

Unpinned Third-Party Dependency Installation

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 48-53
Vulnerability Type: Non-reproducible dependency installation
Risk Level: Low

Affected Code:

bash
pip install Pillow pdf2docx docx2pdf openpyxl xlrd

Duplicated quick-install instruction:

bash
pip install Pillow pdf2docx docx2pdf openpyxl xlrd

Technical Analysis

The Skill instructs users and Agents to install third-party packages without fixed versions or integrity hashes. Package resolution therefore depends on whichever releases are available from the configured package index at installation time.

This installation process is not reproducible and provides no artifact-level integrity verification. If a dependency or one of its transitive dependencies is compromised, replaced, or publishes an incompatible release, installation hooks and imported package code could run locally under the installing user's privileges.

No evidence was found that the listed package names are typosquatted or currently malicious, and the instructions do not specify an untrusted package index. The risk arises from the absence of version and integrity controls rather than from a confirmed malicious dependency.

Attack Path

  1. The user or Agent follows the prerequisite installation instructions.
  2. pip resolves the latest versions from the environment's configured package index.
  3. A dependency or transitive dependency has changed since the Skill was reviewed, or its distribution account or release artifact has been compromised.
  4. pip downloads and installs the unreviewed artifact.
  5. Installation-time behavior or later imports execute the dependency's code with the privileges of the user running the conversion environment.

Impact Assessment

A compromised dependency could potentially read or modify files accessible to the installing user, access the user's environment, or execute arbitrary local code. The maximum scope i ...[truncated 315 chars]

Remediation
View remediation

Remediation Suggestions

  1. Move dependencies into a reviewed lock or requirements file with exact versions.

  2. Record cryptographic hashes for every direct and transitive distribution.

  3. Install with hash verification enabled:

    bash
    python -m pip install --require-hashes -r requirements.txt
    
  4. Generate and review the lock file using a dependency-management tool that resolves transitive packages.

  5. Install dependencies inside a dedicated virtual environment rather than the system Python environment.

  6. Periodically update pinned versions after security and compatibility review.

  7. Use a trusted internal package mirror or explicitly approved package index where appropriate.

  8. Add automated dependency vulnerability and provenance scanning to the release process.

Vulnerability Patterns
  • 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
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
Findings (17)

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the skill actually includes undeclared PDF merge, split, or metadata inspection features while advertising unrelated conversion behavior, that concealment weakens user consent and reviewability. Hidden file-manipulation capabilities are dangerous because they can process, combine, or expose document contents in ways the user and policy reviewers did not approve.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the skill actually includes undeclared PDF merge, split, or metadata inspection features while advertising unrelated conversion behavior, that concealment weakens user consent and reviewability. Hidden file-manipulation capabilities are dangerous because they can process, combine, or expose document contents in ways the user and policy reviewers did not approve.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

If the skill actually includes undeclared PDF merge, split, or metadata inspection features while advertising unrelated conversion behavior, that concealment weakens user consent and reviewability. Hidden file-manipulation capabilities are dangerous because they can process, combine, or expose document contents in ways the user and policy reviewers did not approve.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the skill actually includes undeclared PDF merge, split, or metadata inspection features while advertising unrelated conversion behavior, that concealment weakens user consent and reviewability. Hidden file-manipulation capabilities are dangerous because they can process, combine, or expose document contents in ways the user and policy reviewers did not approve.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the skill actually includes undeclared PDF merge, split, or metadata inspection features while advertising unrelated conversion behavior, that concealment weakens user consent and reviewability. Hidden file-manipulation capabilities are dangerous because they can process, combine, or expose document contents in ways the user and policy reviewers did not approve.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the skill actually includes undeclared PDF merge, split, or metadata inspection features while advertising unrelated conversion behavior, that concealment weakens user consent and reviewability. Hidden file-manipulation capabilities are dangerous because they can process, combine, or expose document contents in ways the user and policy reviewers did not approve.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
88% confidence
Finding

The skill documents file-reading and file-writing behavior but does not declare any explicit tool scope such as permissions or allowed-tools. That creates an authorization ambiguity where an agent may invoke filesystem-capable actions without a clearly constrained contract, increasing the chance of unintended file access or modification.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

Generic trigger keywords like 'convert' or '转换' are too broad and can match many benign conversations, causing inappropriate skill selection. In a skill that can create or modify files, accidental activation increases the risk of unintended filesystem operations and user confusion.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The activation guidance is broad enough that ordinary user requests about files or formats could invoke this skill unnecessarily. Over-broad triggering is dangerous in a file-manipulation skill because it can lead to unintended reads, writes, conversions, or batch operations when the user did not clearly request them.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The skill instructs batch conversion and output generation but does not warn about file creation, overwrite collisions, destination selection, or the scale of bulk changes. That omission is risky because users may unintentionally modify large sets of files or lose data through naming conflicts and unclear output behavior.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The manifest claims comprehensive conversion support including PDF to Word, Word to PDF, image-to-image conversions across several formats, and Excel/CSV bidirectional conversion. This file's actual behavior is limited to PDF/image operations and does not implement the broader set of conversions implied by the skill description.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This code file contains natural-language documentation and command help entirely in Chinese, including the module docstring and usage examples. Because the skill does not offer an alternative language or user opt-in, it can violate a language/locale policy that requires choice rather than forcing a specific language.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest describes file format conversion capabilities such as PDF↔Word, image format conversion, and Excel/CSV conversion. This script also provides PDF merge, split, and info/metadata inspection commands, which are document-manipulation and inspection features rather than format conversion behavior.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The CLI help text says --no-header will 'Skip header row', implying the first row should be omitted from output. In convert_excel_to_csv, the code always calls writer.writerow(row_values) before checking include_header, and the subsequent conditional at L175-L176 does nothing, so the documented behavior contradicts the implementation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

This code file contains natural-language instructions, examples, help text, and error messages only in Chinese. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale restriction is explicitly justified, which is not present here.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

The manifest describes this skill as providing file format conversion, specifically Excel/CSV bidirectional conversion and other format conversions. This file also implements get_excel_info, which reads workbook metadata and sheet dimensions without performing any conversion, adding behavior outside the stated conversion purpose.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
98% confidence
Finding

The CLI documentation and help text declare --start and --end options for page selection, implying users can restrict conversion to a page range. However, main() never passes args.start or args.end into convert_single_pdf(), and convert_single_pdf() hardcodes start=0, end=None, so the script always converts all pages.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.