A free, read-only check for Supabase apps. It finds the keys, MCP servers and settings that give an agent too much power.
$ karchi-guard scan ./my-app BLAST RADIUS: an AI agent working here has enough access to: - read every row in every table (B1 .env:2) - run any SQL, including DROP TABLE (B2 .mcp.json:7) - delete the whole project, and its backups (B2 .mcp.json:7) - reach every project in your account (B2 .mcp.json:7) 8 findings: 2 CRITICAL, 5 HIGH, 1 MEDIUM [CRITICAL] B3 Supabase MCP server 'supabase' is not read-only Fix: add read_only=true to the URL
Apps built with Lovable, Bolt, Cursor or Claude Code often keep a service key in .env, an MCP server with write access, and no backup outside Supabase. An agent that goes wrong can use all of it.
In April 2026 a Cursor agent deleted a production data volume and its backups, using a token it found in an unrelated file.
A token that can delete your project can also take your backups with it. A copy outside Supabase is the only safe copy.
It reads files in your repo, and with --home your agent configs too. No network, no database, no account.
service_role and sb_secret_ keys in files, .env and your built frontendVITE_ or NEXT_PUBLIC_ variables, which ship to every visitorsupabase db reset --linked, supabase projects delete or drop table?.env without asking?bypassPermissions mode?Python 3.11 or newer. Nothing else to install. It exits with code 1 on any critical finding, so it can fail a CI job.
git clone https://github.com/karthikkushi/karchi-guard cd karchi-guard PYTHONPATH=src python3 -m karchi_guard scan /path/to/your/app
- uses: actions/checkout@v4 - uses: karthikkushi/karchi-guard@v0
I run three checks on a local copy of your schema, write a plain-English report, and send the fix as a pull request.
One Supabase project, up to about 15 tables. Delivered in 48 hours.
supabase db advisors --type securityNo. The free check reads files on your machine. For the $49 fix I only need the repo, or a schema-only dump with no data. Keys that leaked should be rotated by you, in your own dashboard.
Use the Advisor; the fix includes it. It checks your database rules. It does not check what your AI agent can reach. In our test app it also missed a policy that let any logged-in user read every order. The user A vs user B test caught it.
No. Karchi Guard is an independent open-source project (MIT license) by Karthik, a developer in India.