Security context

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

xai-org/grok-build
main @ bc7f02e
4
Fixes
0
CVEs
HIGH
Peak severity
0.0%
Coverage
Highlights
Auth Bypass: 1 prior fix. Scrutinize any change in this area.
crates/codegen/xai-grok-config/src/config_override.rs: most-fixed (1 issue). Treat as high-risk during review.
4 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.

Command Injection: Runner-controlled environment variables (e.g., CLAUDE_PROJECT_DIR) were expanded into hook command paths and then executed via sh -c/PowerShell, allowing an attacker to alter the command. The fix skips these vars during expansion, but any other env var or expansion path may still be exploitable.
Path Traversal: File reference resolution could escape the workspace boundary, enabling reads/writes outside the intended directory. The fix enforces workspace confinement, but alternate resolution paths (e.g., in other workspace operations) may not enforce the same check.
Auth Bypass: Attacker-controlled config patches could inject an 'auth_provider' command table, effectively bypassing authentication and enabling arbitrary command execution. The fix strips that key from patches, but other patch keys or merge paths might still inject privileged configuration.