grpo-rl-training

Fail

Audited by Gen Agent Trust Hub on Oct 2, 2026

Risk Level: HIGHDYNAMIC_EXECUTIONINDIRECT_PROMPT_INJECTIONCOMMAND_EXECUTION
Full Analysis
  • [DYNAMIC_EXECUTION]: The file examples/reward_functions_library.py contains a run_test_cases function that uses the built-in exec() function to execute Python code extracted from model generations.
  • Evidence: exec(code, exec_globals) call within examples/reward_functions_library.py.
  • Context: This function is intended to verify the correctness of code produced by a model during training. Although the code includes a developer warning regarding the necessity of sandboxing, the template as provided executes arbitrary strings on the host system, which could be exploited to run malicious code if the model output is manipulated.
  • [INDIRECT_PROMPT_INJECTION]: The skill architecture creates a significant attack surface for indirect prompt injection by processing untrusted model completions through powerful execution tools.
  • Ingestion points: The completions parameter in all reward functions, specifically code_execution_reward in examples/reward_functions_library.py.
  • Boundary markers: There are no implementation-level delimiters or validation steps to ensure that the code being executed does not contain malicious system-level instructions.
  • Capability inventory: The run_test_cases function (called by code_execution_reward) provides full arbitrary code execution capabilities via exec().
  • Sanitization: No code-level sanitization or sandboxing (like Docker or gVisor) is implemented in the template; it relies solely on a documentation warning.
Recommendations
  • AI detected serious security threats
Audit Metadata
Risk Level
HIGH
Analyzed
Oct 2, 2026, 07:18 PM