subprocess module call
Medium
- Category
- Dangerous Code Execution
- Content
log_path = workspace / log_rel try: completed = subprocess.run(cmd, check=False, capture_output=True, text=True) if completed.stdout or completed.stderr or completed.returncode != 0: ensure_dir(log_path.parent) body = [- Confidence
- 91% confidence
- Finding
- The code launches an external Python script via subprocess using workspace-derived arguments such as unit_id, inputs, outputs, and checkpoint. Even though shell injection is mitigated by passing a list and not using shell=True, this still creates a powerful arbitrary-execution path over untrusted workflow data and materially exceeds the declared purpose of an argument self-check skill.
