Back to skill

Security audit

PDF文档工具(免费版)

Security checks for vulnerabilities and agentic risk

Overview

The skill is a mostly coherent PDF utility, but its broad command, write, API, and file-operation language is under-scoped for a document tool.

Review this before installing. Use it only for intended PDF tasks, prefer a sandbox or virtual environment, pin dependencies yourself, avoid processing confidential documents through any external service unless explicitly approved, and write outputs to new files rather than overwriting originals.

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

T08 · Insecure Dependencies

Warning
Location
SKILL.md:124
Finding

Unpinned Third-Party Python Dependencies

Content
View full analysis

Vulnerability Details

File Location: SKILL.md:124-127 and SKILL.md:216-221
Vulnerability Type: Unpinned and unverifiable third-party dependencies
Risk Level: Medium

Vulnerable Code Snippets:

bash
# Ensure Python is available
python3 --version

# Dependencies
pip install requests
markdown
| Dependency | Type | Required | Installation |
|:-----------|:-----|:---------|:-------------|
| LLM API | API | Required | Provided by the Agent's built-in LLM |
| pypdf | Python library | Required | pip install pypdf |
| pdfplumber | Python library | Recommended | pip install pdfplumber |
| reportlab | Python library | Optional | pip install reportlab |
| pytesseract | Python library | Optional | pip install pytesseract |

Technical Analysis

The Skill instructs the Agent to install third-party Python packages without fixed versions, cryptographic hashes, a lockfile, or an explicitly trusted package index. Each installation therefore resolves whichever package release is available from the configured index at execution time.

Python packages may execute installation or build logic under the privileges of the user running pip. If an upstream package, release process, package-index account, or configured package repository is compromised, following these instructions could execute attacker-controlled code. Mutable dependency resolution also creates reproducibility and compatibility risks because a release installed in the future may differ from the release originally reviewed.

The requests installation is not justified by the provided local PDF-processing example, increasing the dependency and supply-chain attack surface without a clearly documented functional requirement. The audit did not find evidence that any named package is currently malicious; the finding concerns the unsafe dependency-management practice.

Attack Path

  1. An Agent loads the Skill and follows its enviro ...[truncated 1625 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove requests unless a documented feature requires it.
  2. Pin every dependency to a reviewed, exact version rather than resolving an unconstrained latest release.
  3. Store dependencies in a version-controlled requirements or lock file.
  4. Generate and enforce cryptographic hashes, for example with pip install --require-hashes -r requirements.txt.
  5. Configure an explicitly trusted package index or internally controlled package mirror.
  6. Review transitive dependencies and update them through a controlled vulnerability-management process.
  7. Install packages inside a dedicated virtual environment or disposable sandbox using a non-privileged account.
  8. Do not run package installation with administrator or root privileges.
  9. Separate optional OCR and document-generation dependencies into feature-specific dependency groups so they are installed only when needed.
  10. Document tested Python and package versions to ensure reproducible deployments.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (7)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The description advertises OCR and processing convenience but does not warn about privacy implications of handling sensitive document contents, especially if OCR or future API-backed features may involve external components. Users may assume all processing is local and safe when documents could contain confidential personal or business data.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill supports file-modifying operations such as merge, split, watermark, encryption, and rotation, but the description does not clearly warn about irreversible changes, overwrites, or output-file handling. In an agent context with write access, missing safety prompts can lead to unintended document modification or data loss.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

Claiming support for generic create/query/modify/delete modes is inconsistent with a PDF utility and broadens the interpreted authority of the skill. In an agent setting, vague CRUD language can justify arbitrary state-changing actions on files or external resources beyond the intended PDF task.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The skill introduces external API/service integration despite being framed as a local PDF-processing tool. That mismatch increases the risk that document contents or metadata could be sent to external services without clear user understanding, especially in workflows involving OCR or automation.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill is presented as a PDF-processing tool but later claims broad capabilities such as API integration, generic automation, command execution, and information retrieval. This scope expansion can mislead an agent into using exec/read/write for tasks outside the user’s expected document-processing context, increasing the chance of unnecessary file access or command execution.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
79% confidence
Finding

The surrounding documentation frames the skill as local PDF processing, yet the environment setup specifically installs 'requests', which is for network communication rather than PDF handling. This creates a documentation-level contradiction about the skill's actual operating model.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
91% confidence
Finding

The file states '无需额外API Key' for the skill, implying no API credential handling is involved. Later, the security section includes API-key handling guidance, which contradicts the earlier claim and suggests external-service credential use is part of operation.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.