subprocess module call
Medium
- Category
- Dangerous Code Execution
- Content
def run(cmd: str, cwd: str) -> str: p = subprocess.run(cmd, shell=True, cwd=cwd, capture_output=True, text=True) return p.stdout + p.stderr- Confidence
- 95% confidence
- Finding
- p = subprocess.run(cmd, shell=True, cwd=cwd, capture_output=True, text=True)
