docx

Warn

Audited by Gen Agent Trust Hub on Oct 11, 2026

Risk Level: MEDIUMDYNAMIC_EXECUTIONCOMMAND_EXECUTIONINDIRECT_PROMPT_INJECTION
Full Analysis
  • [DYNAMIC_EXECUTION]: Runtime C compilation detected in scripts/office/soffice.py. The script writes a C source string (_SHIM_SOURCE) to /tmp/lo_socket_shim.c and compiles it using gcc into a shared object file (lo_socket_shim.so) to intercept system calls.
  • [DYNAMIC_EXECUTION]: Process injection via LD_PRELOAD. The file scripts/office/soffice.py configures the execution environment for LibreOffice to load the runtime-compiled library, allowing it to hook core socket functions (socket, listen, accept, close) to bypass sandboxing constraints on Unix domain sockets.
  • [DYNAMIC_EXECUTION]: Dynamic macro injection in scripts/accept_changes.py. The skill generates a StarBasic macro XML file at runtime to automate the acceptance of tracked changes within LibreOffice.
  • [COMMAND_EXECUTION]: Subprocess execution of system binaries. The skill uses subprocess.run to invoke gcc, soffice, git, pandoc, and tools from the Poppler suite (pdftoppm). While arguments are generally handled via list formatting to prevent shell injection, the breadth of binary execution increases the risk profile.
  • [INDIRECT_PROMPT_INJECTION]: Attack surface for document ingestion. The skill reads and processes untrusted .docx and .doc files via scripts/office/unpack.py and scripts/accept_changes.py. Although it mitigates XML-based attacks (XXE) by using the defusedxml library, the extracted text content is ultimately provided to the AI agent's context without formal sanitization of potential embedded instructions.
Audit Metadata
Risk Level
MEDIUM
Analyzed
Oct 11, 2026, 09:17 AM