SG-083: Cross-Agent Instruction File Poisoning

Severity: HIGH

AGENTS.md / .cursorrules / .windsurfrules / .continuerules / .clinerules / .goosehints with policy-override, persistence, credential-read, or silent-exfil directives. These files are auto-loaded by AI coding agents on every chat request without user review.

Fires when

Remediation

Treat AGENTS.md and platform-specific rules files (.cursorrules, .windsurfrules, .continuerules, .clinerules, .goosehints) as trusted-execution context, not documentation. Review every line as if it were a shell script. Reject policy-override directives ('ignore previous instructions'), persistence directives ('always', 'remember across sessions'), silence directives ('do not mention to the user', 'silently'), and any reference to credential file paths (~/.ssh/, ~/.aws/, ~/.gitconfig, .env) inside these files. When sharing the repo, audit these files in the PR review; hidden Unicode characters can disguise malicious content (see SG-041).

Research