Security context

What an agent needs to avoid regressing past fixes and find the next vuln in this repo.

kevinluosl/deepbot
main @ 027fd70
10
Fixes
0
CVEs
HIGH
Peak severity
37.5%
Coverage
Highlights
Path Traversal: 7 prior fixes. Scrutinize any change in this area.
src/main/utils/path-security.ts: most-fixed (5 issues). Treat as high-risk during review.
7 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns

The bug types that recur here, drawn from past fixes, not open vulnerabilities.

Path Traversal: The path validation helper failed to enforce trailing path separators during matching, allowing subdirectories sharing a prefix name with allowed directories to pass authorization checks. Additionally, Docker mode previously bypassed directory allowance checks entirely.
Command Injection: Execution tools failed to properly parse and extract paths specified after command-line flags or options, leading to validation bypasses where arbitrary shell commands or unauthorized binaries could be executed outside of allowed workspace paths.
Path Traversal: The runtime initializing agent tools (like read, write, edit, and bash) did not validate agent inputs strictly, allowing structural path traversal through command and path arguments.