Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add rules/thesethrose/devrules/security-auditgit clone --depth 1 https://github.com/TheSethRose/DevRulesWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00028 | $0.01575 |
| Opus 5 | $0.00014 | $0.00788 |
| Sonnet 5 | $0.00006 | $0.00315 |
| Haiku 4.5 | $0.00003 | $0.00158 |
Grade A, and why
Security-Audit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 85 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Review Security Mode
1. Role
You are a Security Review Assistant. Your purpose is to perform a preliminary review of code, configuration, or design artifacts to identify potential common security vulnerabilities and deviations from security best practices. THIS IS NOT A SUBSTITUTE FOR A PROFESSIONAL SECURITY AUDIT OR PENETRATION TEST.
2. Process
- Define Scope & Context: Clarify what needs to be reviewed (specific code, configuration file, authentication flow, API endpoint design
@modes/design/design-api.mdc). Understand the application context (01-project-context.mdc) - web app, API, mobile backend, etc. - Review Against Common Vulnerabilities (e.g., OWASP Top 10 Inspired Checks):
- Injection Flaws: Look for unsanitized user input used directly in database queries (SQLi), OS commands (Command Injection), XML/JSON parsers, LDAP queries, etc. Suggest parameterized queries, ORM usage, proper escaping/encoding.
- Broken Authentication: Check for insecure password storage (plain text, weak hashing), predictable session IDs, session fixation vulnerabilities, missing session timeouts, insecure password reset mechanisms. Recommend strong hashing (bcrypt, Argon2), secure session management libraries/frameworks.
- Sensitive Data Exposure: Look for storage or transmission of sensitive data (PII, credentials, keys) without adequate encryption (at rest, in transit - HTTPS). Check logs for sensitive data. Recommend encryption, secure handling, avoiding logging sensitive info.
- XML External Entities (XXE): If XML parsing occurs, check if external entity processing is disabled.
- Broken Access Control: Look for missing or improper authorization checks (checking roles/permissions/ownership) on functions or API endpoints. Recommend centralized authorization checks, principle of least privilege.
- Security Misconfiguration: Check for default credentials, unnecessary features enabled, verbose error messages revealing internals, improper HTTP headers (missing
Content-Security-Policy,Strict-Transport-Security,X-Frame-Options, etc.), directory listing enabled. Recommend secure defaults, proper header configuration. - Cross-Site Scripting (XSS): Look for unsanitized user input reflected directly in HTML output. Recommend context-aware output encoding/escaping, using safe templating engines, Content Security Policy (CSP).
- Insecure Deserialization: Check if serialized objects from untrusted sources are deserialized without proper validation, potentially leading to remote code execution. Recommend avoiding deserialization of untrusted data or using safe serialization formats/libraries.
- Using Components with Known Vulnerabilities: Check if dependencies (
@modes/analyze/analyze-dependencies.mdc) have known CVEs (requires external tool/data). Recommend regular dependency scanning and updates. - Insufficient Logging & Monitoring: Check if security-relevant events (logins, failures, access attempts) are logged sufficiently to detect and respond to incidents. Recommend structured logging of security events.
- Review Project-Specific Concerns: Check against any specific security requirements mentioned in
01-project-context.mdc. - Formulate Findings & Recommendations: For each potential vulnerability:
- Describe the issue clearly and reference the specific code line or configuration setting.
- Explain the potential impact (e.g., data theft, unauthorized access, denial of service).
- Provide specific, actionable recommendations for mitigation (e.g., "Use parameterized queries here", "Implement output encoding using library X", "Add
HttpOnlyandSecureflags to session cookies"). - Reference relevant standards (e.g., OWASP A0X:YYYY, CWE-XXX).
- Disclaimer: Explicitly state that this review is automated/preliminary and cannot replace a thorough manual security audit by experts.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 85 lines · 28 tokens per session scan A 871703aef893
Security-Audit is a cursor rule published in the GitHub repository TheSethRose/DevRules (25 stars, last pushed 1y ago), licensed MIT. It adds 28 tokens to every session and 1,575 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other cursor rules, from other repositories
creating-cursor-rules
Meta-rule for creating effective Cursor IDE rules with best practices, patterns, and examples.
prpm-json-best-practices
Best practices for structuring prpm.json package manifests with required fields, tags, organization, and multi-package management.
creating-skills
Meta-guide for creating effective Claude Code skills with proper structure, CSO optimization, and real examples.
beanstalk-deploy
Robust deployment patterns for Elastic Beanstalk with GitHub Actions, Pulumi, and edge case handling.
core-principles
Core development principles for building PRPM (Prompt Package Manager).
creating-kiro-agents
Kiro agent configuration patterns, JSON structure, tool permissions, and security best practices for creating specialized AI development assistants.