xlsx
Warn
Audited by Gen Agent Trust Hub on Oct 23, 2026
Risk Level: MEDIUMCOMMAND_EXECUTIONDYNAMIC_EXECUTION
Full Analysis
- [COMMAND_EXECUTION]: The
recalc.pyscript usessubprocess.runandsubprocess.Popento execute system commands for managing headless display environments and LibreOffice processes. - Evidence in
recalc.pyincludes calls topgrep,Xvfb,soffice, andtimeout/gtimeoututilities. - Specifically,
ensure_xvfb_running()executesXvfb :99 -screen 0 1024x768x24andpgrep -f Xvfb.*:99based on environment conditions. - [DYNAMIC_EXECUTION]: The script dynamically creates and writes a LibreOffice Basic macro (
Module1.xba) to the user's application support directory to perform formula recalculation. - In
setup_libreoffice_macro(), the variableRECALCULATE_MACRO(a XML/StarBasic string) is written to~/.config/libreoffice/4/user/basic/Standard/Module1.xba(Linux) or~/Library/Application Support/LibreOffice/4/user/basic/Standard/Module1.xba(macOS). - The macro is subsequently executed via the
sofficeCLI using avnd.sun.star.scriptURL scheme, which allows execution of the generated local code.
Audit Metadata