Hi everyone, I'm Aviv, the author of vibe-shield. Disclosure up front: this is my own project. It is MIT licensed, free, has no hosted service, and makes no network calls when it scans.
I built it because coding agents (Claude Code, Cursor, Codex and friends) tend to write Supabase code that works but quietly skips the security parts. The patterns I kept seeing were:
SUPABASE_SERVICE_ROLE_KEY placed behind a NEXT_PUBLIC_ variable, or a createClient(url, serviceRoleKey) helper that ends up imported from a client component.CREATE TABLE migrations with no ENABLE ROW LEVEL SECURITY anywhere in the project, or policies such as USING (true) and GRANT ... TO anon.anon/authenticated that never reference auth.uid() or auth.jwt().Aviv from VibeFoundry introduces 'vibe-shield', a static scanner designed to identify security gaps in Supabase applications, particularly those written by AI. The tool checks for common issues such as service role exposure and missing RLS policies. Aviv seeks feedback on false positives and additional patterns to catch.
vibe-shield is a static scanner for those shapes. It builds a best-effort import graph (literal imports, re-exports, relative paths and tsconfig aliases) so it can flag a service-role client that is reachable from client code, and it keeps a cross-file index of tables versus RLS statements so a CREATE TABLE in one migration is matched against an ENABLE ROW LEVEL SECURITY in another.
Try it on a project:
npx -y @vibefoundry/vibe-shield@latest scan .
Note on versions: the newest GitHub release is v2.1.0, but the npm publish for it failed, so @latest on npm is still 2.0.0. To run the newest CLI today, use the GitHub tag:
npx -y github:avivgerz-hue/vibe-shield#v2.1.0 scan .
It also runs as an MCP server (vibe-shield mcp) so an agent can call the scan as a tool, and it can output SARIF for GitHub code scanning, or fail a CI job with --fail-on high.
Honest limitations, because I would rather you know them:
import 'server-only' and per-request authorization checks still matter.I would really appreciate feedback, especially false positives on real Supabase projects and RLS patterns you think it should catch but does not. Issues and PRs are welcome.