Skip to content

Access control

Supabase policy that lets anyone through (`using (true)`)access.supabase-permissive-policy

A policy whose condition is `true` does not check anything — RLS is "on" but every row is allowed. On insert/update/delete it means anyone with the anon key can change any row.

  • In force Rule access.supabase-permissive-policy
  • 3 clauses

At a glance

access.supabase-permissive-policy
Severityhigh
CertaintyObserved — the code as written is the problem
Looks atyour source code
When it runsRuns on every scan

How to fix it

Replace `true` with a condition on the caller, e.g. `auth.uid() = user_id`, and restrict the policy to the `authenticated` role where possible.

Check your own app

Run npx scanlyfix scan in your project. Every finding gets an id; after fixing, npx scanlyfix verify <id> proves it is gone.

If it is a false positive in your project, silence that one line with // scanlyfix-ignore-next-line access.supabase-permissive-policy -- <why>.

All rules

Your code stays
on your machine

Only findings are uploaded, and only to your own dashboard.