sympy

Warn

Audited by Gen Agent Trust Hub on Oct 23, 2026

Risk Level: MEDIUMDYNAMIC_EXECUTIONINDIRECT_PROMPT_INJECTIONEXTERNAL_DOWNLOADS
Full Analysis
  • [DYNAMIC_EXECUTION]: The skill documents the use of autowrap and ufuncify in references/code-generation-printing.md. These functions generate C or Fortran source code from symbolic expressions, compile them at runtime (using Cython or f2py), and execute the resulting binary. This pattern represents dynamic code generation and execution.
  • [DYNAMIC_EXECUTION]: The documentation includes instructions for using pickle.load() in references/code-generation-printing.md to load saved SymPy expressions. Python's pickle module is known for being vulnerable to arbitrary code execution if used with untrusted data files.
  • [INDIRECT_PROMPT_INJECTION]: The skill exposes a surface for indirect prompt injection by documenting the parse_expr() function in references/code-generation-printing.md. This function is a wrapper for Python's eval() and can be exploited if an agent processes untrusted strings containing mathematical expressions.
  • Ingestion points: Untrusted mathematical strings are processed via parse_expr(), parse_latex(), and parse_mathematica() in references/code-generation-printing.md.
  • Boundary markers: No explicit boundary markers or 'ignore embedded instructions' prompts are suggested for the data ingestion phase.
  • Capability inventory: The skill has access to codegen for file writing, autowrap for shell-level compilation, and eval via the parsing functions, all documented in references/code-generation-printing.md.
  • Sanitization: The skill provides a parse_trusted_expr example in references/code-generation-printing.md that uses a regex-based whitelist (re.search(r'__|import|=')) to filter some malicious Python patterns, though this is not a comprehensive sandbox.
  • [EXTERNAL_DOWNLOADS]: The skill facilitates the installation of the sympy library and its dependencies (NumPy, SciPy, Matplotlib) from the official Python Package Index (PyPI).
Audit Metadata
Risk Level
MEDIUM
Analyzed
Oct 23, 2026, 03:12 AM