pdf-processor

Pass

Audited by Gen Agent Trust Hub on Sep 19, 2026

Risk Level: SAFECOMMAND_EXECUTIONDATA_EXFILTRATIONINDIRECT_PROMPT_INJECTIONDYNAMIC_EXECUTION
Full Analysis
  • [COMMAND_EXECUTION]: The skill uses subprocess.run to interact with system tools and maintain file metadata.
  • Executes ocrmypdf and tesseract for local OCR tasks in scripts/pdf-ocr.py.
  • Uses the SetFile utility on macOS to preserve file creation timestamps in scripts/pdf-preprocess-core.py and scripts/pdf-compress.py.
  • Invokes curl as a fallback mechanism for robust file uploads to external OCR APIs in scripts/pdf_runtime.py when standard libraries fail.
  • [DATA_EXFILTRATION]: PDF content is transmitted to external endpoints for OCR processing as part of the core functionality.
  • Uploads files to endpoints at mineru.net (Shanghai AI Lab/OpenXLab) and aistudio.baidu.com (Baidu/PaddleOCR).
  • The behavior is transparently documented and can be restricted to local-only processing via the --local-only flag.
  • [INDIRECT_PROMPT_INJECTION]: The skill processes untrusted PDF files, presenting a vulnerability surface for indirect injection via OCR extraction.
  • Ingestion points: Document content enters the agent context through file reading in scripts/pdf-ocr.py and scripts/pdf-preprocess-ocr.py.
  • Boundary markers: No explicit markers or "ignore instructions" warnings are applied to the extracted text passed to the LLM.
  • Capability inventory: The skill possesses file-write, network-access, and command-execution capabilities that could be abused if malicious instructions are processed.
  • Sanitization: Performs character normalization (NFKC) and whitespace cleaning but lacks semantic sanitization of the extracted text content.
  • [DYNAMIC_EXECUTION]: The skill utilizes dynamic loading for internal module orchestration.
  • Uses importlib.util and importlib.import_module() to load internal logic from pdf-preprocess-core.py, pdf-compress.py, and various OCR backends at runtime.
Audit Metadata
Risk Level
SAFE
Analyzed
Sep 19, 2026, 03:49 AM