Dev.to Security πŸ” Cybersecurity πŸ‘ 0 πŸ“– 2 min read

Supabase RLS checker: how to test your tables for free, by hand and from outside (proofforge.live)

If you searched for a free Supabase RLS checker, here is what a check from the outside actually does, how to run one by hand, and what it cannot tell you. What "RLS off" looks like from outside Your Supabase

If you searched for a free Supabase RLS checker, here is what a check from the outside actually does, how to run one by hand, and what it cannot tell you.

What "RLS off" looks like from outside

Your Supabase project exposes every table in the public schema through a REST endpoint. The anon key is meant to be public. Row level security decides what that key can read. A table with RLS disabled, or a policy of using (true), answers to anyone.

Manual check, no tools

For each table, with only the anon key:

curl "https://YOUR-PROJECT.supabase.co/rest/v1/YOUR_TABLE?select=*&limit=1" \
  -H "apikey: YOUR_ANON_KEY" -H "Authorization: Bearer YOUR_ANON_KEY"

A row back from a private table is a leak. An empty array [] can mean RLS is working, or the table is empty, so check with a table you know has data.

Check the policies themselves

In the SQL editor:

select schemaname, tablename, rowsecurity from pg_tables where schemaname = 'public';
select tablename, policyname, cmd, qual from pg_policies where schemaname = 'public';

Look for rowsecurity = false and for qual equal to true.

Also check

  • Storage buckets set to public that hold private files
  • rpc() functions marked SECURITY DEFINER with no checks
  • Realtime channels that broadcast row changes

What an outside checker cannot see

It tests what the anon role can reach. It does not know which rows should belong to which user. For that, use two test accounts and try to read one's rows as the other.

An automated outside scan can run the anon-key test across your tables and report pass, fail or inconclusive. Use it as a fast first pass, not a full audit.

Check your own app from the outside, free. Run the free ProofForge scan on your live URL. No account needed for the first scan. It looks at your public site the way a stranger would and says pass, fail or inconclusive, so you know what is confirmed and what it could not see. One-time reports start at $9: see pricing. Building with an AI agent? There is an MCP server so it can check before it deploys.

πŸ“° Read the original article on Dev.to Security

Originally published by Dev.to Security. Aggregated on AIWithGhost for educational purposes β€” full credit and traffic to the original publisher.