Skip to content
WeChat · Goumang Security Lab·Indexed by this site · Originally published· Tools →· Its place in the scan record →SelectedAttention40

cc-safety-net hands-on test: blocks rm -rf, stops .env reads, a 2107-star open-source coding agent safety gate

「Claude Code护栏实测:cc-safety-net拦rm -rf、堵.env读取,2107星开源AI安全工具」

AI summary

The Jumang Security Lab tested the open-source tool cc-safety-net hands-on: it locally parses coding agents' commands before execution, intercepts destructive operations and reads of key files, and makes judgments without calling a model. The tool plugs into the tool-call hooks of 16 coding CLIs including Claude Code. The author tested ten sets of commands; git reset --hard, cat ~/.ssh/id_rsa, and curl piped execution were all blocked, and git push --force was blocked while --force-with-lease was allowed. Policies come in three levels—standard, strict, and paranoid—and the 10 catastrophic rules cannot be turned off at any level; key protection is active at every level, covering .env, SSH private keys, ~/.aws, and more. The article also sorts through the ten boundaries the tool itself acknowledges: it is not a sandbox, it does not read inside scripts, flock wrappers are not expanded, and it allows execution when some hosts crash; the threat model is a well-intentioned but error-prone agent, not a malicious attacker.

Why it was selected

The author tested ten sets of commands and sorted through the ten limitations the tool itself acknowledges, explaining that this pre-execution gate guards against agent slips rather than attackers who already have permissions.

Read originalmp.weixin.qq.com