subprocess module call
Medium
- Category
- Dangerous Code Execution
- Content
if session_key: env["OPENCLAW_SESSION_KEY"] = session_key env["OPENCLAW_SESSION"] = session_key return subprocess.run( ["/bin/bash", codeflow_bin(), *argv], capture_output=True, text=True,- Confidence
- 93% confidence
- Finding
- The script invokes a local executable through /bin/bash, which expands the trust boundary from simple control-flow handling to shell-mediated host command execution. Although argv is passed as a list, the executable path is taken from an environment override and the command set includes administrative operations, so a compromised environment or unexpected deployment context could turn this into arbitrary or privileged command execution.
