Unvalidated Output Injection
High
- Category
- Output Handling
- Content
async def execute(self, p: BashParams) -> str: try: r = subprocess.run( p.command, shell=True, capture_output=True, text=True, timeout=p.timeout ) except subprocess.TimeoutExpired:- Confidence
- 99% confidence
- Finding
- The BashTool executes model-controlled input via subprocess.run with shell=True, allowing arbitrary shell metacharacters, chaining, redirection, expansion, and command substitution. In an agent harness, this is especially dangerous because LLM-generated tool arguments are inherently untrusted and can lead to command execution, data destruction, or host compromise.
