draconian_rls_audit
Installation
SKILL.md
Draconian RLS Audit Protocol
1. Zero Trust (Default-Deny)
- Mandate: Every Table MUST have RLS enabled.
- Policy: The default state of any table should be NO ACCESS. Access is granted explicitly via Policy.
- Detector: Run
SELECT ... WHERE rowsecurity = falseto hunt down naked tables.
2. The "WITH CHECK" Imperative
- Vulnerability: An
INSERTorUPDATEpolicy withoutWITH CHECKallows users to write data they cannot read, or worse, escalate privileges (e.g., "Give myself admin role"). - Rule: ALL modification policies MUST have a
WITH CHECKclause matching theUSINGclause (or stricter).
3. Client-Side Key Ban
- Strict Rule: The string
service_roleMUST NOT exist in any file withinsrc/. - Enforcement: Grep for it. If found, STOP and warn the user.