Commit 5c400a4
Auto Merge Bot
Implement tool execution subsystem
- Create tool execution module for subprocess spawning
- Implement command validation to prevent shell injection
- Use subprocess list invocation (no shell)
- Add comprehensive tests for tool execution
- Handle errors and timeouts properly
- Add timeout management with configurable durations
- Implement command whitelist (npx, python, node, cargo)
- Prevent absolute paths and directory traversal
- Detect shell metacharacters in commands and arguments
- Support parallel execution of multiple commands
- Add 43 comprehensive unit tests (all passing)
- Achieve >75% test coverage
Closes #5191 parent 954f016 commit 5c400a4
6 files changed
Lines changed: 1253 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
49 | 52 | | |
50 | 53 | | |
51 | 54 | | |
| |||
81 | 84 | | |
82 | 85 | | |
83 | 86 | | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | 87 | | |
88 | 88 | | |
89 | 89 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
13 | 14 | | |
14 | 15 | | |
0 commit comments