What problem does it solve?
Convex backends often ship with exploitable authorization gaps: identity taken from client-supplied arguments, missing per-document ownership checks, PII-leaking public queries, and writes into containers the caller does not own. This Skill finds and fixes those four defect shapes deterministically instead of relying on ad-hoc review.
Core Features & Use Cases
- Deterministic 4-shape scan: Regex-based detection of identity-from-arg, missing-ownership-check, PII-leaking queries, and parent-reference write violations across convex*.ts files.
- Canonical hardening: Applies the requireIdentity/requireOwner pattern from convex-expert.md to every hit, including subject-to-users-row resolution and membership checks for container writes.
- Foundation gating: Verifies auth.config.ts and a subject-keyed users table exist before injecting ctx.auth enforcement; on foundationless apps it internalizes privileged functions and defers.
- Use Case: Before shipping a Convex app, run the audit to find every public mutation that trusts a client-supplied userId, rewrite them to derive identity from ctx.auth, and confirm with tsc plus a clean re-scan.
Quick Start
Audit the Convex backend in this project for authorization vulnerabilities and harden every public query and mutation you flag.