This repository has been archived on 2026-06-13. You can view files and clone it, but cannot push or open issues or pull requests.
anvillm/cmd/anvilmcp
Levi Neely 0d847f96f3 execute_code: configurable sandbox, fix dangerous patterns
- Add sandbox parameter to execute_code (default: anvilmcp)
- Load sandbox config from ~/.config/anvillm/sandbox/<name>.yaml
- Fallback to ./cfg/sandbox/<name>.yaml for development
- Add cwd config option: 'temp' for isolated workspace, '{CWD}' for caller's dir
- Create cfg/sandbox/anvilmcp.yaml with restricted defaults
- Update cfg/sandbox/default.yaml with cwd: '{CWD}'

Dangerous pattern fixes (bash, not JS/Python):
- Remove curl/wget block (network controlled by landrun)
- Remove chmod 777, eval(), exec() (wrong syntax)
- Allow /etc/passwd (world-readable, needed for user lookups)
- Fix /dev/ write check to only block /dev/sd* (not /dev/null)
- Fix eval pattern for actual bash usage

Update skills with explicit sandbox specifications:
- anvilmcp sandbox for normal operations
- default sandbox for spawn_agent.sh (needs full permissions)
2026-03-06 09:53:41 +01:00
..
anvilmcp execute_code: configurable sandbox, fix dangerous patterns 2026-03-06 09:53:41 +01:00
execute.go execute_code: configurable sandbox, fix dangerous patterns 2026-03-06 09:53:41 +01:00
execute_test.go Implement MCP code execution pattern (#20) 2026-02-26 14:02:54 +01:00
main.go execute_code: configurable sandbox, fix dangerous patterns 2026-03-06 09:53:41 +01:00
metrics.go Implement MCP code execution pattern (#20) 2026-02-26 14:02:54 +01:00